| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 // patch classes for Int8List ..... Float64List and ByteData implementations. | 5 // patch classes for Int8List ..... Float64List and ByteData implementations. |
| 6 | 6 |
| 7 patch class Int8List { | 7 patch class Int8List { |
| 8 /* patch */ factory Int8List(int length) { | 8 /* patch */ factory Int8List(int length) { |
| 9 return new _Int8Array(length); | 9 return new _Int8Array(length); |
| 10 } | 10 } |
| (...skipping 473 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 484 if (!_setRange(start, length, from, startFrom)) { | 484 if (!_setRange(start, length, from, startFrom)) { |
| 485 IterableMixinWorkaround.setRangeList(this, start, | 485 IterableMixinWorkaround.setRangeList(this, start, |
| 486 length, from, startFrom); | 486 length, from, startFrom); |
| 487 } | 487 } |
| 488 } | 488 } |
| 489 | 489 |
| 490 | 490 |
| 491 // Method(s) implementing Object interface. | 491 // Method(s) implementing Object interface. |
| 492 | 492 |
| 493 String toString() { | 493 String toString() { |
| 494 return Collections.collectionToString(this); | 494 return ToString.iterableToString(this); |
| 495 } | 495 } |
| 496 | 496 |
| 497 | 497 |
| 498 // Internal utility methods. | 498 // Internal utility methods. |
| 499 | 499 |
| 500 bool _setRange(int start, int length, List from, startFrom) | 500 bool _setRange(int start, int length, List from, startFrom) |
| 501 native "TypedData_setRange"; | 501 native "TypedData_setRange"; |
| 502 } | 502 } |
| 503 | 503 |
| 504 | 504 |
| (...skipping 2574 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3079 return value; | 3079 return value; |
| 3080 } | 3080 } |
| 3081 return object; | 3081 return object; |
| 3082 } | 3082 } |
| 3083 | 3083 |
| 3084 | 3084 |
| 3085 void _throwRangeError(int index, int length) { | 3085 void _throwRangeError(int index, int length) { |
| 3086 String message = "$index must be in the range [0..$length)"; | 3086 String message = "$index must be in the range [0..$length)"; |
| 3087 throw new RangeError(message); | 3087 throw new RangeError(message); |
| 3088 } | 3088 } |
| OLD | NEW |