Hello AnomalousMonk,
The output can’t be exactly the same across versions 5.8 to 5.14, because in 5.14.0 the (?^...) construct was added to signify default modifiers (see perl5140delta#Regular-Expressions). So, from 5.14 on, the output is:
14:13 >perl 1868_SoPW.pl (?^:(?).*u\/ba$) A: match (?^msx: \A foo (?^:(?).*u\/ba$) ) B: match 14:13 >
But with that caveat, the behaviour is identical across my Strawberry Perl versions 5.12.3, 5.14.4, 5.18.2, 5.20.2, 5.22.0, 5.24.1, and 5.26.0.
My guess — and it’s no more than a guess — is that the documentation is wrong, and should read: Zero or more embedded pattern-match modifiers ...
Hope that helps,
| Athanasius <°(((>< contra mundum | Iustus alius egestas vitae, eros Piratica, |
In reply to Re: Regex: Embedded pattern-match modifiers: Empty (?) modifier
by Athanasius
in thread Regex: Embedded pattern-match modifiers: Empty (?) modifier
by AnomalousMonk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |