mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-15 23:09:05 +00:00
LibRegex: Don't treat single-jump blocks as noop in the optimizer
This commit is contained in:
parent
868981a46b
commit
5355710481
Notes:
github-actions[bot]
2025-03-09 13:38:58 +00:00
Author: https://github.com/alimpfard
Commit: 5355710481
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3870
2 changed files with 77 additions and 5 deletions
|
@ -1074,6 +1074,8 @@ TEST_CASE(optimizer_atomic_groups)
|
|||
Tuple { "(b+)(b+)"sv, "bbb"sv, true },
|
||||
// Don't treat [\S] as [\s]; see ladybird#2296.
|
||||
Tuple { "([^\\s]+?)\\(([\\s\\S]*)\\)"sv, "a(b)"sv, true },
|
||||
// Follow direct jumps in the optimizer instead of assuming they're a noop.
|
||||
Tuple { "(|[^]*)\\)"sv, "p)"sv, true },
|
||||
};
|
||||
|
||||
for (auto& test : tests) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue