mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-07-04 20:44:18 +00:00
Fixed AS3 - direct editation - arguments object on method with activation
This commit is contained in:
@@ -11,6 +11,7 @@ All notable changes to this project will be documented in this file.
|
||||
- [#1762] AS3 - Auto adding returnvoid/return undefined
|
||||
- [#1762] AS - switch detection (mostcommon pathpart)
|
||||
- [#1763] AS3 - initialization of activation object in some cases
|
||||
- AS3 - direct editation - arguments object on method with activation
|
||||
|
||||
## [15.0.0] - 2021-11-29
|
||||
### Added
|
||||
|
||||
@@ -1689,8 +1689,10 @@ public class AVM2SourceGenerator implements SourceGenerator {
|
||||
NameAVM2Item n = (NameAVM2Item) an;
|
||||
if (n.getVariableName().equals("arguments") & !n.isDefinition()) {
|
||||
registerNames.add("arguments");
|
||||
registerTypes.add(new TypeItem("Object"));
|
||||
registerTypes.add(new TypeItem("Array"));
|
||||
registerLines.add(0); //?
|
||||
slotNames.add(n.getVariableName());
|
||||
slotTypes.add(new TypeItem("Array"));
|
||||
hasArguments = true;
|
||||
break;
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -16,7 +16,7 @@
|
||||
</define>
|
||||
<define append="true">
|
||||
<name>CONFIG::timeStamp</name>
|
||||
<value>'02.12.2021'</value>
|
||||
<value>'04.12.2021'</value>
|
||||
</define>
|
||||
<define append="true">
|
||||
<name>CONFIG::air</name>
|
||||
|
||||
@@ -15,6 +15,7 @@ package
|
||||
*/
|
||||
public class Main extends Sprite
|
||||
{
|
||||
TestActivationArguments;
|
||||
TestArguments;
|
||||
TestCatchFinally;
|
||||
TestChain2;
|
||||
|
||||
16
libsrc/ffdec_lib/testdata/as3_new/src/tests/TestActivationArguments.as
vendored
Normal file
16
libsrc/ffdec_lib/testdata/as3_new/src/tests/TestActivationArguments.as
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
package tests
|
||||
{
|
||||
|
||||
public class TestActivationArguments
|
||||
{
|
||||
public function run():*
|
||||
{
|
||||
var func:Function = function(a:int, b:int):int {
|
||||
return a + b;
|
||||
}
|
||||
if (arguments.length > 0){
|
||||
trace(arguments[0]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user