mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-06-02 08:15:09 +00:00
Fixed: #2322 More AS3 Assigment position when using dup
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -100,6 +100,7 @@ package
|
||||
TestOperations;
|
||||
TestOptimization;
|
||||
TestOptimizationAndOr;
|
||||
TestOptimizationWhile;
|
||||
TestOptionalParameters;
|
||||
TestParamNames;
|
||||
TestParamsCount;
|
||||
|
||||
29
libsrc/ffdec_lib/testdata/as3_new/src/tests/TestOptimizationWhile.as
vendored
Normal file
29
libsrc/ffdec_lib/testdata/as3_new/src/tests/TestOptimizationWhile.as
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
package tests
|
||||
{
|
||||
|
||||
public class TestOptimizationWhile
|
||||
{
|
||||
public function run():*
|
||||
{
|
||||
// Add more than 3 variables.
|
||||
// Optimization happens from register 4 on.
|
||||
// (setlocal X takes more bytes than dup)
|
||||
var a:int = 1;
|
||||
var b:int = 2;
|
||||
var c:int = 3;
|
||||
|
||||
var d:int = 4;
|
||||
|
||||
while(true)
|
||||
{
|
||||
d = Math.round(Math.random() * 10);
|
||||
if(d >= 10)
|
||||
{
|
||||
break;
|
||||
}
|
||||
trace("xxx");
|
||||
d++;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user