mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 20:29:18 +00:00
LibRegex: Remove the StringCopyMatches mode
This mode made a lot of incorrect assumptions about string lifetimes, and instead of fixing it, let's just remove it and tweak the few unit tests that used it.
This commit is contained in:
parent
f1914893e9
commit
6b6d3b32a4
Notes:
github-actions[bot]
2025-03-24 22:28:15 +00:00
Author: https://github.com/awesomekling
Commit: 6b6d3b32a4
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4067
Reviewed-by: https://github.com/trflynn89
6 changed files with 14 additions and 29 deletions
|
@ -25,7 +25,6 @@ enum class AllFlags {
|
|||
MatchNotBeginOfLine = __Regex_MatchNotBeginOfLine, // Pattern is not forced to ^ -> search in whole string!
|
||||
MatchNotEndOfLine = __Regex_MatchNotEndOfLine, // Don't Force the dollar sign, $, to always match end of the string, instead of end of the line. This option is ignored if the Multiline-flag is set
|
||||
SkipSubExprResults = __Regex_SkipSubExprResults, // Do not return sub expressions in the result
|
||||
StringCopyMatches = __Regex_StringCopyMatches, // Do explicitly copy results into new allocated string instead of StringView to original string.
|
||||
SingleLine = __Regex_SingleLine, // Dot matches newline characters
|
||||
Sticky = __Regex_Sticky, // Force the pattern to only match consecutive matches from where the previous match ended.
|
||||
Multiline = __Regex_Multiline, // Handle newline characters. Match each line, one by one.
|
||||
|
@ -53,7 +52,6 @@ enum class PosixFlags : FlagsUnderlyingType {
|
|||
SkipTrimEmptyMatches = (FlagsUnderlyingType)AllFlags::SkipTrimEmptyMatches,
|
||||
Multiline = (FlagsUnderlyingType)AllFlags::Multiline,
|
||||
SingleMatch = (FlagsUnderlyingType)AllFlags::SingleMatch,
|
||||
StringCopyMatches = (FlagsUnderlyingType)AllFlags::StringCopyMatches,
|
||||
};
|
||||
|
||||
enum class ECMAScriptFlags : FlagsUnderlyingType {
|
||||
|
@ -67,7 +65,6 @@ enum class ECMAScriptFlags : FlagsUnderlyingType {
|
|||
SingleLine = (FlagsUnderlyingType)AllFlags::SingleLine,
|
||||
Sticky = (FlagsUnderlyingType)AllFlags::Sticky,
|
||||
Multiline = (FlagsUnderlyingType)AllFlags::Multiline,
|
||||
StringCopyMatches = (FlagsUnderlyingType)AllFlags::StringCopyMatches,
|
||||
UnicodeSets = (FlagsUnderlyingType)AllFlags::UnicodeSets,
|
||||
BrowserExtended = (FlagsUnderlyingType)AllFlags::Internal_BrowserExtended,
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue