JPEXS Free Flash Decompiler Issue Tracker

If you are looking for the decompiler itself, visit

List of issuesList of issues

#46 if then else with empty branches gets ignored
Date created:
Type: bug
Visibility: Everybody
Assigned to:
Labels: DecompilationGoogle Code
State: closed Help

<b>What steps will reproduce the problem?</b> 1. Adding if then else and if then else inside. What is the expected output? if (_loc1_ == &quot;test1&quot;) { trace(&quot;test 1&quot;); if (_loc2_ == &quot;test2&quot;) { trace(&quot;test 2&quot;); } else { trace(&quot;else 2&quot;); } } else { trace(&quot;else 1&quot;); } What do you see instead? if(_loc2_==&quot;test1&quot;) { } <b>What version of the product are you using? On what operating system?</b> 1.4.1 on windows 7 64 bit <b>Could you provide the SWF file you have problem with?</b> <b>If the answer is yes, then please attach it here or send me it via email.</b> <b>Could you at least attach PCode source?</b> <b>Do you have the original source code which produced the wrong</b> <b>decompilation? If yes, then please attach it.</b> <b>Please provide any additional information below.</b>
hi, the trace commands are ignored during compilation with your compiler. The decompiler ignores if commands when there are no commands in both if and else branches, e. g. pushbyte 1 pushbyte 2 ifeq loc1 loc1: However in some cases the if should be visible, because the condition can have side-effect, like if(exec()){ }else{ } I will look on it, and fix it. The code should then look like this: if(_loc2_=="test1") { if (_loc2_ == "test2") { } }
Hi, this is fixed in version 1.4.2, try it.
State: →closed
Title: if then else with empty branches gets ignored→if then else with empty branches gets ignored
Type: →bug
Visibility: →Everybody