mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-05-28 07:46:49 +00:00
Show convert instruction when needed - int(xx), String(xx), etc....
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -10,7 +10,7 @@ package tests
|
||||
|
||||
public function run():void
|
||||
{
|
||||
var a:int = Math.random();
|
||||
var a:int = int(Math.random());
|
||||
|
||||
if (a > 10)
|
||||
{
|
||||
|
||||
@@ -9,7 +9,7 @@ package tests
|
||||
|
||||
public function run() : String
|
||||
{
|
||||
var a:int = Math.random() * 5;
|
||||
var a:int = int(Math.random() * 5);
|
||||
try
|
||||
{
|
||||
trace("before try2");
|
||||
|
||||
@@ -10,7 +10,7 @@ package tests
|
||||
|
||||
public function run() : String
|
||||
{
|
||||
var a:int = Math.random() * 5;
|
||||
var a:int = int(Math.random() * 5);
|
||||
try
|
||||
{
|
||||
try
|
||||
|
||||
@@ -9,7 +9,7 @@ package tests
|
||||
|
||||
public function run() : void
|
||||
{
|
||||
var a:int = Math.random() * 5;
|
||||
var a:int = int(Math.random() * 5);
|
||||
trace("before try");
|
||||
try
|
||||
{
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -22,6 +22,7 @@ package
|
||||
TestCatchFinally;
|
||||
TestChain2;
|
||||
TestChainedAssignments;
|
||||
TestConvert;
|
||||
TestComplexExpressions;
|
||||
TestContinueLevels;
|
||||
TestComma;
|
||||
|
||||
18
libsrc/ffdec_lib/testdata/as3_new/src/tests/TestConvert.as
vendored
Normal file
18
libsrc/ffdec_lib/testdata/as3_new/src/tests/TestConvert.as
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
package tests
|
||||
{
|
||||
|
||||
public class TestConvert
|
||||
{
|
||||
private var n:int = 1;
|
||||
private var ns:String = "b";
|
||||
|
||||
public function run():void
|
||||
{
|
||||
var s:String = "a";
|
||||
var i:int = int(s);
|
||||
var j:int = n;
|
||||
s = String(j);
|
||||
s = ns;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user