JPEXS Free Flash Decompiler Issue Tracker

If you are looking for the decompiler itself, visit https://github.com/jindrapetrik/jpexs-decompiler

NEW : We have got a new blog where we post some interesting SWF internals info.

List of issuesList of issues

#13 for..in, for each..in difference
Date created:
Type: bug
Visibility: Everybody
Assigned to:
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));
admin
Hi, sorry for answering too late. I made some changes to the code - version 1.0.0 is available. This problem should be fixed.
admin
admin
user
State: →closed
Title: for..in, for each..in difference→for..in, for each..in difference
Type: →bug
Visibility: →Everybody