Overview
| Artifact ID: | 81796d50215e7c83cd09d6de47fae143b818bff327019e01aca1cdddffdacfd6 |
|---|---|
| Ticket: | 75c9d9cece5612408603f4e56773f55ada24b2d7
regexp sometimes allows an invalid backref to be matched |
| User & Date: | tgl on 2021-08-23 16:04:19 |
Changes
- assignee changed to: "nobody"
- closer changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
$ tclsh % regexp {^(.)\1|\1.} {abcdef} 1 % regexp {^((.)\2|..)\2} {abadef} 1 Of course, neither of these should match, because the (.) capture is within a failed alternative branch, so the last backref to it should be deemed unable to match. Analysis and fix for it in Postgres is here: https://www.postgresql.org/message-id/151435.1629733387%40sss.pgh.pa.us I doubt you can use the code change exactly as-is, because I don't think you ever adopted our changes to create an explicit "iteration" subre type. But the principle, and particularly the more careful specification of cdissect's recursion rules, should still work for you. - foundin changed to: "8.6.8"
- is_private changed to: "0"
- login: "tgl"
- priority changed to: "5 Medium"
- private_contact changed to: "26864b65f1c6ce8bda86f87ed9c554e19ac0390d"
- resolution changed to: "None"
- severity changed to: "Minor"
- status changed to: "Open"
- submitter changed to: "tgl"
- subsystem changed to: "43. Regexp"
- title changed to:
regexp sometimes allows an invalid backref to be matched
- type changed to: "Bug"