@@ -3,20 +3,16 @@ package {
33 [Ruffle (InstanceAllocator)]
44 public dynamic class Array {
55 public static const CASEINSENSITIVE : uint = 1 ;
6-
76 public static const DESCENDING : uint = 2 ;
8-
97 public static const UNIQUESORT : uint = 4 ;
10-
118 public static const RETURNINDEXEDARRAY : uint = 8 ;
12-
139 public static const NUMERIC : uint = 16 ;
1410
1511 // FIXME avmplus allows for calling some of these prototype functions on any
1612 // Array-like object (for example, `Array.prototype.sort.call(myVector)` works),
1713 // but currently we only support calling them on real Arrays
1814 {
19- prototype . concat = function (... rest): Array {
15+ prototype . concat = function (... rest): Array {
2016 var a : Array = this ;
2117 return a . AS3 :: concat . apply (a , rest);
2218 };
@@ -61,7 +57,7 @@ package {
6157 return a . AS3 :: pop ();
6258 };
6359
64- prototype . push = function (... args ): uint {
60+ prototype . push = function (... args ): uint {
6561 var a : Array = this ;
6662 return a . AS3 :: push . apply (a , args );
6763 };
@@ -86,17 +82,17 @@ package {
8682 return a . AS3 :: some (callback, receiver);
8783 };
8884
89- prototype . sort = function (... rest):* {
85+ prototype . sort = function (... rest):* {
9086 var a : Array = this ;
9187 return a . AS3 :: sort . apply (a , rest);
9288 };
9389
94- prototype . sortOn = function (fieldNames:* , options:* = 0 , ... rest):* {
90+ prototype . sortOn = function (fieldNames:* , options:* = 0 , ... rest):* {
9591 var a : Array = this ;
9692 return a . AS3 :: sortOn (fieldNames, options);
9793 };
9894
99- prototype . splice = function (... rest):* {
95+ prototype . splice = function (... rest):* {
10096 var a : Array = this ;
10197 return a . AS3 :: splice . apply (a , rest);
10298 };
@@ -106,7 +102,7 @@ package {
106102 var result : String = "" ;
107103 var arrayLength: uint = a . length ;
108104
109- for (var i: uint = 0 ; i < arrayLength; i ++ ) {
105+ for (var i: uint = 0 ; i < arrayLength; i ++ ) {
110106 if (a [ i] === void 0 || a [ i] === null ) {
111107 result += a [ i];
112108 } else {
@@ -126,7 +122,7 @@ package {
126122 return a . AS3 :: join ("," );
127123 };
128124
129- prototype . unshift = function (... rest): uint {
125+ prototype . unshift = function (... rest): uint {
130126 var a : Array = this ;
131127 return a . AS3 :: unshift . apply (a , rest);
132128 };
@@ -154,10 +150,10 @@ package {
154150 }
155151
156152 // Constructor (defined in Rust)
157- public native function Array (... rest);
153+ public native function Array (... rest);
158154
159155 // Instance methods
160- AS3 native function concat(... rest): Array ;
156+ AS3 native function concat(... rest): Array ;
161157
162158 AS3 native function every(callback: Function , receiver:* = null ): Boolean ;
163159
@@ -188,7 +184,7 @@ package {
188184
189185 AS3 native function pop():*;
190186
191- AS3 native function push(... rest): uint ;
187+ AS3 native function push(... rest): uint ;
192188
193189 [API ("708" )]
194190 AS3 native function removeAt(index: int ):*;
@@ -201,13 +197,13 @@ package {
201197
202198 AS3 native function some(callback: Function , receiver:* = null ): Boolean ;
203199
204- AS3 native function sort(... rest):*;
200+ AS3 native function sort(... rest):*;
205201
206- AS3 native function sortOn(fieldNames:* , options:* = 0 , ... rest):*;
202+ AS3 native function sortOn(fieldNames:* , options:* = 0 , ... rest):*;
207203
208- AS3 native function splice(... rest):*;
204+ AS3 native function splice(... rest):*;
209205
210- AS3 native function unshift(... rest): uint ;
206+ AS3 native function unshift(... rest): uint ;
211207
212208 public static const length: int = 1 ;
213209 }
0 commit comments