nl_tokens: Like Array . prototype . indexOf but searches for a subarray rather than just a particular value .
pl_tokens: function find_subarray ( haystack , needle ) { var h = 0 , n ; var start = <mask> . now ( ) ; HAYSTACK : while ( h !== - 1 ) { h = haystack . indexOf ( needle [ 0 ] , h ) ; if ( h === - 1 ) break HAYSTACK ; for ( n = 1 ; n < needle . length ; n ++ ) { if ( haystack [ h + n ] !== needle [ n ] ) { h ++ ; continue HAYSTACK ; } } return h ; } return - 1 ; }