| Index: lib/core/list.dart
|
| diff --git a/lib/core/list.dart b/lib/core/list.dart
|
| index e44e743974677c650ce08f4dc1621155ec264c06..1262a6eb0e196d3218a7f06cbaf8353b74435791 100644
|
| --- a/lib/core/list.dart
|
| +++ b/lib/core/list.dart
|
| @@ -6,8 +6,7 @@
|
| * A [List] is an indexable collection with a length. It can be of
|
| * fixed size or extendable.
|
| */
|
| -interface List<E> extends Collection<E> default ListImplementation<E> {
|
| -
|
| +abstract class List<E> extends Collection<E> {
|
| /**
|
| * Creates a list of the given [length].
|
| *
|
| @@ -17,13 +16,19 @@ interface List<E> extends Collection<E> default ListImplementation<E> {
|
| * If a [length] argument is supplied, a fixed size list of that
|
| * length is created.
|
| */
|
| - List([int length]);
|
| + external factory List([int length]);
|
|
|
| /**
|
| * Creates a list with the elements of [other]. The order in
|
| * the list will be the order provided by the iterator of [other].
|
| */
|
| - List.from(Iterable<E> other);
|
| + factory List.from(Iterable<E> other) {
|
| + List<E> result = new List<E>();
|
| + for (E element in other) {
|
| + result.add(element);
|
| + }
|
| + return result;
|
| + }
|
|
|
| /**
|
| * Returns the element at the given [index] in the list or throws
|
|
|