Branch: refs/heads/yves/disable_curlyx_with_eval
  Home:   https://github.com/Perl/perl5
  Commit: 51d9f4d0a129157f87a69d71e20520324c844ef3
      
https://github.com/Perl/perl5/commit/51d9f4d0a129157f87a69d71e20520324c844ef3
  Author: Yves Orton <[email protected]>
  Date:   2023-01-15 (Sun, 15 Jan 2023)

  Changed paths:
    M regcomp_internal.h
    M regcomp_study.c

  Log Message:
  -----------
  regcomp_study.c - Add a way to disable CURLYX optimisations

Also break up the condition so there is one condition per line so
it is more readable, and fold repeated binary tests together. This
makes it more obvious what the expression is doing.


  Commit: 050af7a99011138d6bd246ada2a0308d7b656b35
      
https://github.com/Perl/perl5/commit/050af7a99011138d6bd246ada2a0308d7b656b35
  Author: Yves Orton <[email protected]>
  Date:   2023-01-15 (Sun, 15 Jan 2023)

  Changed paths:
    M regcomp_debug.c
    M regcomp_study.c
    M t/re/pat_re_eval.t

  Log Message:
  -----------
  regcomp_study.c - disable CURLYX optimizations when EVAL has been seen 
anywhere

Historically we disabled CURLYX optimizations when they
*contained* an EVAL, on the assumption that the optimization might
affect how many times, etc, the eval was called. However, this is
also true for CURLYX with evals *afterwards*. If the CURLYN or CURLYM
optimization can prune off the search space, then an eval afterwards
will be affected. An when you take into account GOSUB, it means that
an eval in front might be affected by an optimization after it.

So for now we disable CURLYN and CURLYM in any pattern with an EVAL.


Compare: https://github.com/Perl/perl5/compare/51d9f4d0a129%5E...050af7a99011

Reply via email to