diff options
author | mihaylov <mihaylov@epfl.ch> | 2006-03-10 10:22:20 +0000 |
---|---|---|
committer | mihaylov <mihaylov@epfl.ch> | 2006-03-10 10:22:20 +0000 |
commit | 8c8b95f3ed4bc13887dcf4fc2ae07bd48c2c463c (patch) | |
tree | 6f02b766f2de81ed078a10e70a27ff0bc453ddb5 | |
parent | 1c43d5e932d9466765e2d3f64fc220981098703e (diff) | |
download | scala-8c8b95f3ed4bc13887dcf4fc2ae07bd48c2c463c.tar.gz scala-8c8b95f3ed4bc13887dcf4fc2ae07bd48c2c463c.tar.bz2 scala-8c8b95f3ed4bc13887dcf4fc2ae07bd48c2c463c.zip |
Reintroduced the toList method for efficiency
-rw-r--r-- | src/library/scala/List.scala | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/library/scala/List.scala b/src/library/scala/List.scala index c9f5789310..c80b0c24e2 100644 --- a/src/library/scala/List.scala +++ b/src/library/scala/List.scala @@ -473,11 +473,11 @@ sealed abstract class List[+a] extends Seq[a] { } } - /** Transform this sequence into a list of all elements. - * - * @return a list which enumerates all elements of this sequence. - */ - //override def toList: List[a] = this; //!!! + /** Overrides the method in Iterable for efficiency. + * + * @return the list itself + */ + override def toList: List[a] = this; /** Returns the list without its last element. * |