Add support for d flag of regex literals in parser (#13396)

This commit is contained in:
Yosuke Ota
2021-05-31 21:34:53 +09:00
committed by GitHub
parent 813f2a3cce
commit 0b29b5c2c0
3 changed files with 28 additions and 1 deletions

View File

@@ -21,7 +21,7 @@ import {
import State from "./state";
import type { LookaheadState } from "./state";
const VALID_REGEX_FLAGS = new Set(["g", "m", "s", "i", "y", "u"]);
const VALID_REGEX_FLAGS = new Set(["g", "m", "s", "i", "y", "u", "d"]);
// The following character codes are forbidden from being
// an immediate sibling of NumericLiteralSeparator _