From a1cab0447eb9584eed452006787bc905a4479d93 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 17 Oct 2023 11:05:31 +0900 Subject: [PATCH] chore(deps): update dependency eslint-plugin-regexp to v2 (#183) * chore(deps): update dependency eslint-plugin-regexp to v2 * fix --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Yosuke Ota --- package.json | 2 +- src/parser/validate.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index c1d3632..79a86bf 100644 --- a/package.json +++ b/package.json @@ -71,7 +71,7 @@ "eslint-plugin-n": "^16.0.0", "eslint-plugin-node-dependencies": "^0.11.0", "eslint-plugin-prettier": "^5.0.0", - "eslint-plugin-regexp": "^1.0.0", + "eslint-plugin-regexp": "^2.0.0", "eslint-plugin-vue": "^9.0.0", "mocha": "^10.0.0", "nyc": "^15.1.0", diff --git a/src/parser/validate.ts b/src/parser/validate.ts index 6daf9b8..e2277b9 100644 --- a/src/parser/validate.ts +++ b/src/parser/validate.ts @@ -26,9 +26,9 @@ import type { JSONIdentifier } from "./ast"; import type { JSONSyntaxContext } from "./syntax-context"; const lineBreakPattern = /\r\n|[\n\r\u2028\u2029]/u; -const octalNumericLiteralPattern = /^0[Oo]/u; +const octalNumericLiteralPattern = /^0o/iu; const legacyOctalNumericLiteralPattern = /^0\d/u; -const binaryNumericLiteralPattern = /^0[Bb]/u; +const binaryNumericLiteralPattern = /^0b/iu; const unicodeCodepointEscapePattern = /\\u\{[\dA-Fa-f]+\}/uy;