mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-06-20 22:55:32 +00:00
Fixed #2202 AS2 return in constructor does not take a value
This commit is contained in:
BIN
libsrc/ffdec_lib/testdata/as2/as2.swf
vendored
BIN
libsrc/ffdec_lib/testdata/as2/as2.swf
vendored
Binary file not shown.
@@ -8,5 +8,6 @@ class com.jpexs.flash.test.TestLoader {
|
||||
new com.jpexs.flash.test.testcases.TestCallSetterGetter();
|
||||
new com.jpexs.flash.test.testcases.TestVarsMethods();
|
||||
new com.jpexs.flash.test.testcases.TestMaintainOrder();
|
||||
new com.jpexs.flash.test.testcases.TestReturnInConstructor();
|
||||
}
|
||||
}
|
||||
21
libsrc/ffdec_lib/testdata/as2/com/jpexs/flash/test/testcases/TestReturnInConstructor.as
vendored
Normal file
21
libsrc/ffdec_lib/testdata/as2/com/jpexs/flash/test/testcases/TestReturnInConstructor.as
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
class com.jpexs.flash.test.testcases.TestReturnInConstructor {
|
||||
|
||||
public function TestReturnInConstructor(){
|
||||
var k = 3;
|
||||
if (k == 3) {
|
||||
trace("A");
|
||||
return;
|
||||
}
|
||||
trace("B");
|
||||
}
|
||||
|
||||
public function func() {
|
||||
var k = 3;
|
||||
if (k == 3) {
|
||||
trace("A");
|
||||
return undefined;
|
||||
}
|
||||
trace("B");
|
||||
return 5;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user