fix(javascript): preserve uncertainty in compound assignment results (#4342)

* fix(javascript): preserve uncertainty in compound assignment results

* fix(javascript): retain callable logical assignment alternatives

* fix(javascript): read prior module export assignment values

* fix: keep mutable module export assignment candidates conservative

* fix: preserve mixed receiver values and wrapped assignment targets

* fix: carry mutable export uncertainty through copied values
This commit is contained in:
Liu Jie
2026-10-17 05:24:09 +13:00
committed by GitHub
parent abbdb46427
commit 17488bd639
4 changed files with 705 additions and 36 deletions
@@ -9,6 +9,7 @@ export const symbolicLogicalRight = (
operator: t.LogicalExpression["operator"],
left: SymbolicValue,
): boolean | undefined => {
if (left.kind === "namespace" && left.runtimeValueUnknown) return undefined;
if (left.kind === "union") {
const choices = left.values.map((value) =>
symbolicLogicalRight(operator, value),