mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-06-01 19:04:38 +00:00
#349 AS3 - better handling of declarations
This commit is contained in:
Binary file not shown.
@@ -16,5 +16,6 @@ program
|
||||
#include "tests/TestDup.script.asasm"
|
||||
#include "tests/TestSwitchDefault.script.asasm"
|
||||
#include "tests/TestSwitch.script.asasm"
|
||||
#include "tests/TestDeclareReg.script.asasm"
|
||||
; place to add next
|
||||
end ; program
|
||||
|
||||
76
libsrc/ffdec_lib/testdata/as3_assembled/abc/as3_assembled-0/tests/TestDeclareReg.class.asasm
vendored
Normal file
76
libsrc/ffdec_lib/testdata/as3_assembled/abc/as3_assembled-0/tests/TestDeclareReg.class.asasm
vendored
Normal file
@@ -0,0 +1,76 @@
|
||||
class
|
||||
refid "tests:TestDeclareReg"
|
||||
instance QName(PackageNamespace("tests"), "TestDeclareReg")
|
||||
extends QName(PackageNamespace(""), "Object")
|
||||
flag SEALED
|
||||
flag PROTECTEDNS
|
||||
protectedns ProtectedNamespace("tests:TestDeclareReg")
|
||||
iinit
|
||||
refid "tests:TestDeclareReg/instance/init"
|
||||
body
|
||||
maxstack 1
|
||||
localcount 1
|
||||
initscopedepth 4
|
||||
maxscopedepth 5
|
||||
code
|
||||
getlocal0
|
||||
pushscope
|
||||
|
||||
getlocal0
|
||||
constructsuper 0
|
||||
|
||||
returnvoid
|
||||
end ; code
|
||||
end ; body
|
||||
end ; method
|
||||
trait method QName(PackageNamespace(""), "run")
|
||||
method
|
||||
refid "tests:TestDeclareReg/instance/run"
|
||||
returns QName(PackageNamespace(""), "void")
|
||||
body
|
||||
maxstack 2
|
||||
localcount 4
|
||||
initscopedepth 4
|
||||
maxscopedepth 5
|
||||
code
|
||||
getlocal0
|
||||
pushscope
|
||||
newactivation
|
||||
dup
|
||||
setlocal2
|
||||
pushscope
|
||||
getscopeobject 1
|
||||
getslot 1
|
||||
dup
|
||||
setlocal3
|
||||
pushwith
|
||||
findpropstrict QName(PackageNamespace(""),"trace")
|
||||
pushstring "hey"
|
||||
callpropvoid QName(PackageNamespace(""),"trace"), 1
|
||||
popscope
|
||||
returnvoid
|
||||
end ; code
|
||||
trait slot QName(PackageInternalNs("something"),"other")
|
||||
slotid 1
|
||||
type QName(PackageNamespace(""),"XML")
|
||||
end ; trait
|
||||
end ; body
|
||||
end ; method
|
||||
end ; trait
|
||||
end ; instance
|
||||
cinit
|
||||
refid "tests:TestDeclareReg/class/init"
|
||||
body
|
||||
maxstack 1
|
||||
localcount 1
|
||||
initscopedepth 3
|
||||
maxscopedepth 4
|
||||
code
|
||||
getlocal0
|
||||
pushscope
|
||||
|
||||
returnvoid
|
||||
end ; code
|
||||
end ; body
|
||||
end ; method
|
||||
end ; class
|
||||
29
libsrc/ffdec_lib/testdata/as3_assembled/abc/as3_assembled-0/tests/TestDeclareReg.script.asasm
vendored
Normal file
29
libsrc/ffdec_lib/testdata/as3_assembled/abc/as3_assembled-0/tests/TestDeclareReg.script.asasm
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
script
|
||||
sinit
|
||||
refid "tests:TestDeclareReg/init"
|
||||
body
|
||||
maxstack 2
|
||||
localcount 1
|
||||
initscopedepth 1
|
||||
maxscopedepth 3
|
||||
code
|
||||
getlocal0
|
||||
pushscope
|
||||
|
||||
findpropstrict Multiname("TestDeclareReg", [PackageNamespace("tests")])
|
||||
getlex QName(PackageNamespace(""), "Object")
|
||||
pushscope
|
||||
|
||||
getlex Multiname("Object", [PrivateNamespace(null, "tests:TestDeclareReg"), PackageNamespace(""), PackageNamespace("tests"), PackageInternalNs("tests"), Namespace("http://adobe.com/AS3/2006/builtin")])
|
||||
newclass "tests:TestDeclareReg"
|
||||
popscope
|
||||
initproperty QName(PackageNamespace("tests"), "TestDeclareReg")
|
||||
|
||||
returnvoid
|
||||
end ; code
|
||||
end ; body
|
||||
end ; method
|
||||
trait class QName(PackageNamespace("tests"), "TestDeclareReg")
|
||||
#include "TestDeclareReg.class.asasm"
|
||||
end ; trait
|
||||
end ; script
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user