From b7b0118afad57ae3a7861ffa9781ad855d54927f Mon Sep 17 00:00:00 2001 From: Joe Savona Date: Tue, 14 Feb 2023 15:48:52 -0800 Subject: [PATCH] InferReactiveIdentifiers handles Capture effect --- compiler/forget/src/ReactiveScopes/InferReactiveIdentifiers.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/forget/src/ReactiveScopes/InferReactiveIdentifiers.ts b/compiler/forget/src/ReactiveScopes/InferReactiveIdentifiers.ts index 88afebb30c..119c34bb87 100644 --- a/compiler/forget/src/ReactiveScopes/InferReactiveIdentifiers.ts +++ b/compiler/forget/src/ReactiveScopes/InferReactiveIdentifiers.ts @@ -59,6 +59,7 @@ class Environment extends ReactiveFunctionVisitor { // all mutating effects must also be marked as reactive for (const operand of eachReactiveValueOperand(value)) { switch (operand.effect) { + case Effect.Capture: case Effect.Store: case Effect.Mutate: { // Explicitly compare to `false` here, since absence from the @@ -69,7 +70,6 @@ class Environment extends ReactiveFunctionVisitor { } break; } - case Effect.Capture: case Effect.Freeze: case Effect.Read: { // no-op