LibJS: Enable the BrowserExtended ECMA262 regexp flag by default
Fixes #5517.
This commit is contained in:
parent
e0ac85288e
commit
610cec6e72
Notes:
sideshowbarker
2024-07-18 21:53:31 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/610cec6e72a Pull-request: https://github.com/SerenityOS/serenity/pull/5538 Issue: https://github.com/SerenityOS/serenity/issues/5517 Issue: https://github.com/SerenityOS/serenity/issues/5518 Reviewed-by: https://github.com/linusg Reviewed-by: https://github.com/tomuta
1 changed files with 3 additions and 1 deletions
|
@ -37,7 +37,9 @@ static Flags options_from(const String& flags, VM& vm, GlobalObject& global_obje
|
|||
{
|
||||
bool g = false, i = false, m = false, s = false, u = false, y = false;
|
||||
Flags options {
|
||||
{ (regex::ECMAScriptFlags)regex::AllFlags::Global }, // JS regexps are all 'global' by default as per our definition, but the "global" flag enables "stateful".
|
||||
// JS regexps are all 'global' by default as per our definition, but the "global" flag enables "stateful".
|
||||
// FIXME: Enable 'BrowserExtended' only if in a browser context.
|
||||
{ (regex::ECMAScriptFlags)regex::AllFlags::Global | ECMAScriptFlags::BrowserExtended },
|
||||
{},
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue