-
-
Notifications
You must be signed in to change notification settings - Fork 53
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
Behavior of -G length
inconsistent, moreover returns error code.
#478
Labels
Comments
katef
added a commit
that referenced
this issue
Aug 24, 2024
Spotted by @pierreganty (#478), thank you
Finally getting to this, sorry it's taken so long! I think this is a more compelling example:
|
Also a good case:
|
katef
added a commit
that referenced
this issue
Aug 24, 2024
Previously this gave: ``` ; ./build/bin/re -r literal -G 3 abc ; ./build/bin/re -r literal -G 4 abc abc ; ``` and now -G 3 does construct "abc" (not including the newline, which is a property of the printing, not of the constructed string): ``` ; ./build/bin/re -r literal -G 3 abc abc ; ./build/bin/re -r literal -G 4 abc abc ; ``` and: ``` ; ./build/bin/re -r native -G 3 '^x+$' x xx xxx ``` Spotted by @pierreganty (#478), thank you
Nice! Thank you. |
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
When asking
re
for an example of length up to 20 then none is returned.If, for the same regular expression, I ask
re
to return an example of length 21 then it returns two examples, the first of which has length 20.Moreover, in both calls
re
returns1
which is an error code according to the man page. I am not sure why, though.The text was updated successfully, but these errors were encountered: