AS3 p-code more RAbcDasm like

- get/setlocal_x renamed to get/setlocalx
- QName casing changed from Qname

Better increment/decrement detection, chained assignments.
This commit is contained in:
Jindra Petřík
2021-02-08 20:15:19 +01:00
parent 90bf2057fe
commit 98c2b1eba9
53 changed files with 1245 additions and 376 deletions
@@ -0,0 +1,71 @@
class
refid "tests:TestIncrement"
instance QName(PackageNamespace("tests"), "TestIncrement")
extends QName(PackageNamespace(""), "Object")
flag SEALED
flag PROTECTEDNS
protectedns ProtectedNamespace("tests:TestIncrement")
iinit
refid "tests:TestIncrement/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:TestIncrement/instance/run"
returns QName(PackageNamespace(""), "void")
body
maxstack 2
localcount 4
initscopedepth 4
maxscopedepth 5
code
getlocal0
pushscope
getlocal0
constructsuper 0
getlex QName(PrivateNamespace("myns"),"a")
convert_d
dup
increment
findpropstrict QName(PrivateNamespace("myns"),"a")
swap
setproperty QName(PrivateNamespace("myns"),"a")
findproperty QName(PackageNamespace(""),"b")
swap
setproperty QName(PackageNamespace(""),"b")
returnvoid
end ; code
end ; body
end ; method
end ; trait
end ; instance
cinit
refid "tests:TestIncrement/class/init"
body
maxstack 1
localcount 1
initscopedepth 3
maxscopedepth 4
code
getlocal0
pushscope
returnvoid
end ; code
end ; body
end ; method
end ; class