Chromium Code Reviews| Index: sdk/lib/core/list.dart |
| diff --git a/sdk/lib/core/list.dart b/sdk/lib/core/list.dart |
| index 27a857e9df442afb0bc957bb4f861fe10537009b..470d8ce80171fd92ca0cfbf07b14d5cea7177ff5 100644 |
| --- a/sdk/lib/core/list.dart |
| +++ b/sdk/lib/core/list.dart |
| @@ -263,15 +263,19 @@ abstract class List<E> implements Iterable<E> { |
| Iterable<E> getRange(int start, int end); |
| /** |
| - * Copies [length] elements of [from], starting |
| - * at [startFrom], into the list, starting at [start]. |
| - * If [length] is 0, this method does not do anything. |
| - * Throws an [ArgumentError] if [length] is negative. |
| - * Throws an [RangeError] if [start] or |
| - * [:start + length - 1:] are out of range for [:this:], or if |
| - * [startFrom] or [:startFrom + length - 1:] are out of range for [from]. |
| + * Copies the elements of [iterable], skipping the [skipCount] first elements |
|
Anders Johnsen
2013/04/15 09:24:04
first elements,
floitsch
2013/04/15 13:45:34
Done.
|
| + * into the range [start] - [end] of `this`. |
| + * |
| + * If [start] equals [end] and represent a legal range, this method has |
| + * no effect. |
| + * |
| + * It is an error if [start]..[end] is not a valid range pointing into the |
| + * `this`. |
| + * |
| + * It is an error if the [iterable] does not have enough elements after |
| + * skipping [skipCount] elements. |
|
Anders Johnsen
2013/04/15 09:24:04
Will it throw when at end, or before it starts cop
Lasse Reichstein Nielsen
2013/04/15 10:16:10
It must be able to throw at the end, because there
|
| */ |
| - void setRange(int start, int length, List<E> from, [int startFrom]); |
| + void setRange(int start, int end, Iterable<E> iterable, [int skipCount = 0]); |
|
Lasse Reichstein Nielsen
2013/04/15 10:16:10
If this is working on an Iterable, and not the eff
floitsch
2013/04/15 13:45:34
This is the efficient method. Keeping 'skipCount'.
|
| /** |
| * Removes [length] elements from the list, beginning at [start]. |