This repository has been archived by the owner on Jul 3, 2019. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
132 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
package { | ||
public class A { | ||
static var a = 1; | ||
} | ||
|
||
public class B extends A { | ||
static var b = 2; | ||
} | ||
|
||
public class C extends B { | ||
static var c = 3; | ||
static function foo() { | ||
trace(a + b + c); | ||
new Array(Number(10)); | ||
} | ||
function bar() { | ||
var d = 4; | ||
trace(a + b + c); | ||
foo(); | ||
(function () { | ||
var c0 = 0; | ||
(function () { | ||
var c1 = 1; | ||
(function () { | ||
var c2 = 2; | ||
(function () { | ||
var c3 = 3; | ||
(function () { | ||
var c4 = 4; | ||
(function () { | ||
var c5 = 5; | ||
(function () { | ||
var c6 = 6; | ||
(function () { | ||
var c7 = 7; | ||
(function () { | ||
var c8 = 8; | ||
(function () { | ||
var c9 = 9; | ||
(function () { | ||
trace(c0 + c1 + c2 + c3 + c4 + c5 + c6 + c7 + c8 + c9); | ||
})(); | ||
})(); | ||
})(); | ||
})(); | ||
})(); | ||
})(); | ||
})(); | ||
})(); | ||
})(); | ||
})(); | ||
})(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package { | ||
public class A { | ||
public static var x = 32; | ||
public native function get foo() : Boolean; | ||
} | ||
|
||
public class B extends A { | ||
public function get foo() : Boolean { | ||
trace ("B::foo()"); | ||
} | ||
} | ||
|
||
(new A()).foo; | ||
(new B()).foo; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
package { | ||
function foo(o: Array) { | ||
trace("--- Weird Property Names ---"); | ||
o[12356712387125673512] = "Hello"; | ||
o[-0] = "Minus Zero"; | ||
o[1/0] = "INFINITY AND BEYOND"; | ||
o[-1/0] = "NEG INFINITY AND BELOW"; | ||
o["00"] = "DOUBLE ZERO"; | ||
o[NaN] = "NANANANANA"; | ||
o[123.456] = "FLOAT"; | ||
o[123.456e+123] = "HUGE"; | ||
o[123.456789e+123] = "HUGE 2"; | ||
o[123] = "123"; | ||
o["123"] = "XYZ"; | ||
o["12356712387125673512"] = "XYZ"; | ||
o["12356712387125673512"] += " Hello"; | ||
o["-0"] += " Minus Zero"; | ||
o["00"] += " DOUBLE ZERO"; | ||
o["NaN"] += " NANANANANA"; | ||
o["123.456"] += " FLOAT"; | ||
o["123.456e+123"] += " HUGE"; | ||
o["123.456789e+123"] += " HUGE 2"; | ||
o[" "] = "SPACE"; | ||
|
||
trace(o[12356712387125673512]); | ||
trace(o["12356712387125673512"]); | ||
trace(o[0]); | ||
trace(o[Infinity]); | ||
trace(o[-Infinity]); | ||
trace(o["00"]); | ||
trace(o[NaN]); | ||
trace(o[123.456]); | ||
trace(o[123.456e+123]); | ||
trace(o[123.456789e+123]); | ||
trace(o[123.456789e+123567]); | ||
trace(o[" "]); | ||
trace("for"); | ||
var s = 0; | ||
for (var k in o) { | ||
s += String(k).length; | ||
} | ||
trace(s); | ||
} | ||
|
||
(function () { | ||
foo([]); | ||
trace("--- Done ---"); | ||
})(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package { | ||
(function (o) { | ||
trace("--- XML ---"); | ||
trace(o.@x); | ||
})(<a x="HELLO">test</a>); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters