Repository navigation
Commit 28e562d
committed
Reject unknown escapes in REGEXP patterns on PHP 7
PHP 7.3 and 7.4 read unknown escapes as literal text. '\u0041'
silently matched "u0041", and '\p{Foo}' matched nothing instead of
failing. PHP 7.2 did the same for escapes like '\y'. PHP 8 reports
them as errors, as the known differences say.
The "X" modifier makes them errors on PHP 7, too, and does nothing on
PHP 8. MySQL reads unknown escapes like '\y' as literals, so document
that difference as well.1 parent 9975e2c commit 28e562d
3 files changed
Lines changed: 178 additions & 206 deletions
File tree
- packages/mysql-on-sqlite
- src/sqlite
- tests
- regexp
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1056 | 1056 | | |
1057 | 1057 | | |
1058 | 1058 | | |
| 1059 | + | |
1059 | 1060 | | |
1060 | 1061 | | |
1061 | 1062 | | |
| |||
1116 | 1117 | | |
1117 | 1118 | | |
1118 | 1119 | | |
1119 | | - | |
| 1120 | + | |
| 1121 | + | |
| 1122 | + | |
| 1123 | + | |
| 1124 | + | |
1120 | 1125 | | |
1121 | 1126 | | |
1122 | 1127 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
324 | 324 | | |
325 | 325 | | |
326 | 326 | | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
327 | 332 | | |
328 | 333 | | |
329 | 334 | | |
| |||
0 commit comments