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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doc: sem and rep_kind #161

Open
obscurans opened this issue Aug 10, 2018 · 1 comment
Open

Doc: sem and rep_kind #161

obscurans opened this issue Aug 10, 2018 · 1 comment

Comments

@obscurans
Copy link
Contributor

Could you clarify that in Core, the longest/shortest/first/greedy/non_greedy combinators do not change which strings match the regex per execp, and only change the extent of capturing?

@Drup
Copy link
Collaborator

Drup commented Aug 16, 2018

longest/shortest/greedy/non_greedy do affect both matching and capturing. I guess what you mean is that if a string match the long (resp greedy) version, it will also match the short (non greedy) version. I do not remember if that is correct with all the operators we have in re, but I think it works in the posix subset.

I don't remember what's the semantics of first (I guess it only capture the leftmost instance). Which shows that it should be documented indeed. :D

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

No branches or pull requests

2 participants