diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/instructions/SetTypeIns.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/instructions/SetTypeIns.java index 6d977358b..2f8b11c8e 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/instructions/SetTypeIns.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/instructions/SetTypeIns.java @@ -98,6 +98,17 @@ public interface SetTypeIns { } else { result.value = newValue; } + + //Assembled - TestForEach + if (AVM2Item.mustStayIntact2(newValue) && result instanceof SetLocalAVM2Item) { + SetLocalAVM2Item setLocal = (SetLocalAVM2Item) result; + stack.pop(); + stack.moveToStack(output); + stack.addToOutput(result); + stack.push(new LocalRegAVM2Item(null, null, setLocal.regIndex, setLocal.value, setLocal.type)); + return; + } + stack.pop(); stack.moveToStack(output);