Lines Matching defs:next_si

600         let (mut prev_si, mut next_si) = (self.start, self.start);
613 // and `next_si` always represents the next state after the loop
615 while next_si <= STATE_MAX && at < text.len() {
616 // Argument for safety is in the definition of next_si.
617 prev_si = unsafe { self.next_si(next_si, text, at) };
620 mem::swap(&mut prev_si, &mut next_si);
623 next_si = unsafe { self.next_si(prev_si, text, at) };
625 if next_si > STATE_MAX {
628 prev_si = unsafe { self.next_si(next_si, text, at) };
631 mem::swap(&mut prev_si, &mut next_si);
634 next_si = unsafe { self.next_si(prev_si, text, at) };
637 if next_si & STATE_MATCH > 0 {
642 next_si &= !STATE_MATCH;
647 self.last_match_si = next_si;
648 prev_si = next_si;
655 let state = self.state(next_si);
668 while (next_si & !STATE_MATCH) == prev_si
671 // Argument for safety is in the definition of next_si.
672 next_si = unsafe {
673 self.next_si(next_si & !STATE_MATCH, text, at)
680 } else if next_si & STATE_START > 0 {
686 next_si &= !STATE_START;
687 prev_si = next_si;
692 } else if next_si >= STATE_UNKNOWN {
693 if next_si == STATE_QUIT {
708 next_si = match self.next_state(qcur, qnext, prev_si, byte) {
713 debug_assert!(next_si != STATE_UNKNOWN);
714 if next_si & STATE_MATCH > 0 {
715 next_si &= !STATE_MATCH;
720 self.last_match_si = next_si;
722 prev_si = next_si;
724 prev_si = next_si;
762 let (mut prev_si, mut next_si) = (self.start, self.start);
765 while next_si <= STATE_MAX && at > 0 {
766 // Argument for safety is in the definition of next_si.
768 prev_si = unsafe { self.next_si(next_si, text, at) };
770 mem::swap(&mut prev_si, &mut next_si);
774 next_si = unsafe { self.next_si(prev_si, text, at) };
775 if next_si > STATE_MAX {
779 prev_si = unsafe { self.next_si(next_si, text, at) };
781 mem::swap(&mut prev_si, &mut next_si);
785 next_si = unsafe { self.next_si(prev_si, text, at) };
787 if next_si & STATE_MATCH > 0 {
788 next_si &= !STATE_MATCH;
793 self.last_match_si = next_si;
794 prev_si = next_si;
796 while (next_si & !STATE_MATCH) == prev_si && at >= 2 {
797 // Argument for safety is in the definition of next_si.
799 next_si = unsafe {
800 self.next_si(next_si & !STATE_MATCH, text, at)
806 } else if next_si >= STATE_UNKNOWN {
807 if next_si == STATE_QUIT {
813 next_si = match self.next_state(qcur, qnext, prev_si, byte) {
818 debug_assert!(next_si != STATE_UNKNOWN);
819 if next_si & STATE_MATCH > 0 {
820 next_si &= !STATE_MATCH;
825 self.last_match_si = next_si;
827 prev_si = next_si;
829 prev_si = next_si;
848 /// next_si transitions to the next state, where the transition input
853 unsafe fn next_si(&self, si: StatePtr, text: &[u8], i: usize) -> StatePtr {
861 // (1) is only safe when calling next_si is guarded by