cleanup: s/v.slice*()
/&v[a..b]
/g + remove redundant as_slice()
calls
This commit is contained in:
parent
d77f6d5366
commit
bce81e2464
59 changed files with 156 additions and 160 deletions
|
@ -94,7 +94,7 @@ pub fn demangle(writer: &mut Writer, s: &str) -> IoResult<()> {
|
|||
($($pat:expr, => $demangled:expr),*) => ({
|
||||
$(if rest.starts_with($pat) {
|
||||
try!(writer.write_str($demangled));
|
||||
rest = rest.slice_from($pat.len());
|
||||
rest = &rest[$pat.len()..];
|
||||
} else)*
|
||||
{
|
||||
try!(writer.write_str(rest));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue