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
regex metachar tilde fails on .*? content #1255
Comments
From payload@lavabit.comBUG:
TEST: The problem is .*? , i think, cause '(foo)' ~~ /'(' ~ ')' 'foo'/ parrot rev: 40852 |
From @pmichaudOn Sat, Aug 29, 2009 at 02:45:08PM -0700, Gilbert R. Roehrbein (via RT) wrote:
Currently Synopsis 5 is a bit unclear on the handling of backtracking '(' ~ ')' <expression> gets rewritten to be something like '(' <expression> [ ')' || <FAILGOAL> ] Note that there's no way to backtrack into <expression> -- once we've So in the case of the problem regex above, we end up with '(' .*? [ ')' || <FAILGOAL> ] which will match only "()", because there's no possibility of At one time I tried changing the definition of ~ so that it '(' [ <expression> ')' || <FAILGOAL> ] but ISTR that I ran into some other issues there and gave up for the So, short answer is that I think Rakudo is correctly following the
AFAIK none of the related code has been changed between June 30 and today, token comment { '<!--' ~ '-->' <content> } Given that these are all "token" (no backtracking), that would mean that Thanks! Pm |
The RT System itself - Status changed from 'new' to 'open' |
From @pmichaudMarking as resolved, Coke++ for noticing. Pm |
@pmichaud - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#68854 (status was 'resolved')
Searchable as RT68854$
The text was updated successfully, but these errors were encountered: