Skip to content

Commit 375e13a

Browse files
committed
tidy up
1 parent 65cd9f6 commit 375e13a

File tree

3 files changed

+0
-9
lines changed

3 files changed

+0
-9
lines changed

packages/svelte/src/compiler/phases/2-analyze/visitors/Identifier.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -130,11 +130,6 @@ export function Identifier(node, context) {
130130
context.state.expression.has_state = true;
131131
}
132132

133-
// TODO it would be better to just bail out when we hit the ExportSpecifier node but that's
134-
// not currently possibly because of our visitor merging, which I desperately want to nuke
135-
const is_export_specifier =
136-
/** @type {SvelteNode} */ (context.path.at(-1)).type === 'ExportSpecifier';
137-
138133
if (
139134
context.state.analysis.runes &&
140135
node !== binding.node &&
@@ -149,7 +144,6 @@ export function Identifier(node, context) {
149144
!should_proxy_or_freeze(binding.initial.arguments[0], context.state.scope)))) ||
150145
binding.kind === 'frozen_state' ||
151146
binding.kind === 'derived') &&
152-
!is_export_specifier &&
153147
// We're only concerned with reads here
154148
(parent.type !== 'AssignmentExpression' || parent.left !== node) &&
155149
parent.type !== 'UpdateExpression'

packages/svelte/src/compiler/phases/2-analyze/visitors/LabeledStatement.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,6 @@ export function LabeledStatement(node, context) {
6666

6767
context.state.reactive_statements.set(node, reactive_statement);
6868

69-
// Ideally this would be in the validation file, but that isn't possible because this visitor
70-
// calls "next" before setting the reactive statements.
7169
if (
7270
reactive_statement.dependencies.length &&
7371
reactive_statement.dependencies.every(

packages/svelte/src/compiler/phases/2-analyze/visitors/StyleDirective.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ export function StyleDirective(node, context) {
1212
e.style_directive_invalid_modifier(node);
1313
}
1414

15-
// the case for node.value different from true is already covered by the Identifier visitor
1615
if (node.value === true) {
1716
// get the binding for node.name and change the binding to state
1817
let binding = context.state.scope.get(node.name);

0 commit comments

Comments
 (0)