Fix mapInstructionOperands() visitor

Found while debugging the previous issue: `mapInstructionOperands()` should not 
look at lvalues. The previous version was causing us to create extra phi nodes, 
which interestingly weren't the actual problem behind the "SSA" bug, but sure 
looked like it at first.
This commit is contained in:
Joe Savona
2023-03-08 20:49:32 -08:00
parent ff855b1d34
commit 1fb0aed668
-2
View File
@@ -293,12 +293,10 @@ export function mapInstructionOperands(
break;
}
case "StoreLocal": {
instrValue.lvalue.place = fn(instrValue.lvalue.place);
instrValue.value = fn(instrValue.value);
break;
}
case "Destructure": {
mapPatternOperands(instrValue.lvalue.pattern, fn);
instrValue.value = fn(instrValue.value);
break;
}