Skip to content

Commit c60c2d5

Browse files
committed
fix(compiler-core): Remove unnecessary identifier extraction from switch-case tests
1 parent 2f4cdd8 commit c60c2d5

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

packages/compiler-core/src/babelUtils.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -254,12 +254,6 @@ function walkSwitchStatement(
254254
onIdent: (id: Identifier) => void,
255255
) {
256256
for (const cs of stmt.cases) {
257-
if (cs.test) {
258-
for (const id of extractIdentifiers(cs.test)) {
259-
onIdent(id)
260-
}
261-
}
262-
263257
for (const stmt of cs.consequent) {
264258
if (
265259
stmt.type === 'VariableDeclaration' &&

0 commit comments

Comments
 (0)