Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(search) advance stream position even if there is a zero length match #3619

Closed
wants to merge 1 commit into from

Conversation

basarat
Copy link
Contributor

@basarat basarat commented Oct 29, 2015

E.g. if someone search for \b in regex mode the length of the match is 0 and then in readToken it will call the token function However since pos does not change it errors out throw new Error("Mode " + mode.name + " failed to advance stream.");

After the fix

Seems to work fine 馃尮

image

@marijnh
Copy link
Member

marijnh commented Oct 29, 2015

Good idea. Merged as 21f1d0a

@marijnh marijnh closed this Oct 29, 2015
@basarat basarat deleted the patch-1 branch October 29, 2015 23:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants