Fixed #1206 Switch with multiple default clauses

Fixed switch(null) in some cases
This commit is contained in:
Jindra Petřík
2021-01-28 09:40:06 +01:00
parent f6f355f0af
commit 1c981b9c13
10 changed files with 329 additions and 321 deletions

View File

@@ -0,0 +1,29 @@
script
sinit
refid "tests:TestSwitchDefault/init"
body
maxstack 2
localcount 1
initscopedepth 1
maxscopedepth 3
code
getlocal0
pushscope
findpropstrict Multiname("TestSwitchDefault", [PackageNamespace("tests")])
getlex QName(PackageNamespace(""), "Object")
pushscope
getlex Multiname("Object", [PrivateNamespace(null, "tests:TestSwitchDefault"), PackageNamespace(""), PackageNamespace("tests"), PackageInternalNs("tests"), Namespace("http://adobe.com/AS3/2006/builtin")])
newclass "tests:TestSwitchDefault"
popscope
initproperty QName(PackageNamespace("tests"), "TestSwitchDefault")
returnvoid
end ; code
end ; body
end ; method
trait class QName(PackageNamespace("tests"), "TestSwitchDefault")
#include "TestSwitchDefault.class.asasm"
end ; trait
end ; script