Skip to content

Commit 33f414f

Browse files
ota-meshimarijnh
authored andcommitted
refactor to remove unnecessary code
1 parent 1e4161f commit 33f414f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

acorn/src/regexp.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ export class RegExpValidationState {
5050
this.maxBackReference = 0
5151
this.groupNames = Object.create(null)
5252
this.backReferenceNames = []
53-
this.alternative = null
5453
}
5554

5655
reset(start, pattern, flags) {
@@ -228,7 +227,7 @@ pp.regexp_pattern = function(state) {
228227
// https://www.ecma-international.org/ecma-262/8.0/#prod-Disjunction
229228
pp.regexp_disjunction = function(state) {
230229
let trackDisjunction = this.options.ecmaVersion >= 16
231-
if (trackDisjunction) state.branchID = new BranchID(state.branchID, null, 0)
230+
if (trackDisjunction) state.branchID = new BranchID(state.branchID, null)
232231
this.regexp_alternative(state)
233232
while (state.eat(0x7C /* | */)) {
234233
if (trackDisjunction) state.branchID = state.branchID.sibling()

0 commit comments

Comments
 (0)