JPEXS Free Flash Decompiler Issue Tracker

If you are looking for the decompiler itself, visit

List of issuesList of issues

#13, for difference
Date created:
Type: bug
Visibility: Everybody
Assigned to:
Labels: AS3DecompilationGoogle Code
State: closed Help

source code : var dic : Dictionary ; var item : Object ; for ( item in Dictionary ) { ... } for each ( item in Dictionary ) { ... } we can determine it by the instructions "nextname" & "nextvalue" ( nextname for traversal keys & nextvalue for traversal values ) here is my solution 1. add a static variable ( public static Stack<Boolean> isForEachKey ;) 2. when translate the instruction "nextname" ( NextNameIns ) ,push true value in this stack , & push false value when dealing with "nextvalue" 3. add two new class ( EachKeyTreeItem & EachValueTreeItem inherit EachTreeItem ) & overwrite function toString(ConstantPool constants) 4. output.add(new ForEachTreeItem(ins, currentLoop.loopBreak, currentLoop.loopContinue, isForEachKey.pop() ? new EachKeyTreeItem(each) : new EachValueTreeItem(each), loopBody));
Hi, sorry for answering too late. I made some changes to the code - version 1.0.0 is available. This problem should be fixed.
State: →closed
Title:, for difference→, for difference
Type: →bug
Visibility: →Everybody