From 86fa76678bdaa673d88aba0cf2229530b29619da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jindra=20Pet=C5=99=C3=ADk?= Date: Thu, 24 Nov 2022 09:47:48 +0100 Subject: [PATCH] Fixed #1769 Missing some body trait variable declaration --- .../decompiler/flash/abc/avm2/AVM2Code.java | 44 +------------------ 1 file changed, 1 insertion(+), 43 deletions(-) diff --git a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/AVM2Code.java b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/AVM2Code.java index 707ae3cc4..398a9319b 100644 --- a/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/AVM2Code.java +++ b/libsrc/ffdec_lib/src/com/jpexs/decompiler/flash/abc/avm2/AVM2Code.java @@ -2016,49 +2016,7 @@ public class AVM2Code implements Cloneable { int reg = ((LocalRegAVM2Item) fi.expression.object).regIndex; fi.expression.object = handleDeclareReg(minreg, fi.expression.object, declaredRegisters, declaredSlots, reg); } - } - - for (GraphTargetItem subItem : itemsOnLine) { - Multiname propertyMultiName; - String propertyName; - if (subItem instanceof GetPropertyAVM2Item) { - GetPropertyAVM2Item propItem = (GetPropertyAVM2Item) subItem; - if (propItem.object instanceof FindPropertyAVM2Item) { - propertyMultiName = abc.constants.getMultiname(((FullMultinameAVM2Item) propItem.propertyName).multinameIndex); - } else { - continue; - } - } else if (subItem instanceof GetLexAVM2Item) { - GetLexAVM2Item lex = (GetLexAVM2Item) subItem; - propertyMultiName = lex.propertyName; - } else { - continue; - } - propertyName = propertyMultiName.getName(abc.constants, new ArrayList<>(), true, true); - - if (traits.containsKey(propertyName)) { - Slot sl = new Slot(new NewActivationAVM2Item(null, null), propertyMultiName); - if (!paramNames.contains(propertyName)) { - - if (slotListIndexOf(declaredSlots, propertyName, abc) == -1) { - TraitSlotConst tsc = traits.get(propertyName); - GraphTargetItem type = PropertyAVM2Item.multinameToType(tsc.type_index, abc.constants); - DeclarationAVM2Item d = new DeclarationAVM2Item(subItem, type); - declaredSlotsDec.add(d); - declaredSlots.add(sl); - - if (subItem == currentItem) { - items.set(i, d); - } else { - d.showValue = false; - items.add(i, d); - i++; - } - - } - } - } - } + } for (GraphTargetItem subItem : itemsOnLine) { if (subItem instanceof SetLocalAVM2Item) {