Use slice syntax instead of slice_to, etc.

This commit is contained in:
Nick Cameron
2014-09-24 23:41:09 +12:00
parent a70a0374e2
commit 40b9f5ded5
81 changed files with 331 additions and 363 deletions

View File

@@ -145,7 +145,7 @@ impl<'r, 't> Nfa<'r, 't> {
// out early.
if self.prog.prefix.len() > 0 && clist.size == 0 {
let needle = self.prog.prefix.as_slice().as_bytes();
let haystack = self.input.as_bytes().slice_from(self.ic);
let haystack = self.input.as_bytes()[self.ic..];
match find_prefix(needle, haystack) {
None => break,
Some(i) => {