Branch: refs/heads/blead Home: https://github.com/Perl/perl5 Commit: 5efad79033608816c24807b39ca3b76e62f5fb34 https://github.com/Perl/perl5/commit/5efad79033608816c24807b39ca3b76e62f5fb34 Author: Karl Williamson <k...@cpan.org> Date: 2020-04-29 (Wed, 29 Apr 2020)
Changed paths: M regcomp.c Log Message: ----------- Fix panic in Unicode wildcard matching The reason this bug occurs is that wildcard matching changes the anchor assertions \A, \Z, and \z, without corresponding changes in regexec.c. We earlier noticed that all these were being marked SIMPLE, and a zero-width construct shouldn't really be. But it was considered too late in the development cycle to make that change. So the plan was to live with this bug in an experimental feature in 5.32. But I eventually realized that the change could be effected for just the wildcard versions, and this commit does that. If there is some issue with making these non-SIMPLE, it will affect only the wildcard feature, and those potential bugs are better than a known bug. I also seems unlikely that this will introduce any bug. What removing SIMPLE does is merely remove potential optimizations in the handling. The most general case should work.; it's doing an improper optimization that gets one into trouble. This fixes #17677