diff options
author | Kenta Moriuchi <moriken@kimamass.com> | 2023-03-01 08:14:16 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-01 08:14:16 +0900 |
commit | 55833cf799979e63c6b027fbbf018272308caf5c (patch) | |
tree | cc0ae9aa9116e6296e5e74e1c926cfd94fa26449 /core/00_primordials.js | |
parent | 6ffbf8a9410f5ea41669efdece60f7f47f77e3c7 (diff) |
fix(core): introduce `SafeRegExp` to primordials (#17592)
Diffstat (limited to 'core/00_primordials.js')
-rw-r--r-- | core/00_primordials.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/core/00_primordials.js b/core/00_primordials.js index 6495a5268..243f40e88 100644 --- a/core/00_primordials.js +++ b/core/00_primordials.js @@ -434,6 +434,15 @@ }, ); + primordials.SafeRegExp = makeSafe( + RegExp, + class SafeRegExp extends RegExp { + constructor(pattern, flags) { + super(pattern, flags); + } + }, + ); + primordials.SafeFinalizationRegistry = makeSafe( FinalizationRegistry, class SafeFinalizationRegistry extends FinalizationRegistry { |