Mantis - Quercus
|
|||||
Viewing Issue Advanced Details | |||||
|
|||||
ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
2907 | minor | always | 09-05-08 01:23 | 09-09-08 10:56 | |
|
|||||
Reporter: | wikipo | Platform: | |||
Assigned To: | nam | OS: | |||
Priority: | normal | OS Version: | |||
Status: | closed | Product Version: | 3.1.6 | ||
Product Build: | Resolution: | fixed | |||
Projection: | none | ||||
ETA: | none | Fixed in Version: | 3.2.1 | ||
|
|||||
Summary: | 0002907: Regex option 'A' ignored | ||||
Description: |
When a regex expression uses option 'A', the match functions must use the offest specified. I have found this in mediawiki 1.12 code in this expression: $elementsRegex = "~($xmlishRegex)(?:\s|\/>|>)|(!--)~iA"; subsequently used in a call to preg_match with offset specified. |
||||
Steps To Reproduce: | |||||
Additional Information: |
I think the semantics of option 'A' is to anchor the search to the offset specified relative to the beginning of the text, while option '^' means to anchor to the beginning of the text. I changed the test in RegexpNode.AnchorBegin.match: // if (offset == 0) if (offset == state._first) This solves the problem at least for mediawiki. |
||||
Relationships | |||||
Attached Files: |
Notes | |||||
|
|||||
|
|