summaryrefslogtreecommitdiff
path: root/src/library
diff options
context:
space:
mode:
authorJosh Suereth <Joshua.Suereth@gmail.com>2012-06-06 13:19:14 -0700
committerJosh Suereth <Joshua.Suereth@gmail.com>2012-06-06 13:19:14 -0700
commit6cdb6b0299cb917ac3df9e39aa932bacdc31faf9 (patch)
tree3ecf0a4abc770746099cd50ef651cc33d90a8665 /src/library
parent2023f3d2d95c37e7fff1b367e708bb509516f5d8 (diff)
parent5d3f8b9e225a570fd17a36d2a6b4036a0819f646 (diff)
downloadscala-6cdb6b0299cb917ac3df9e39aa932bacdc31faf9.tar.gz
scala-6cdb6b0299cb917ac3df9e39aa932bacdc31faf9.tar.bz2
scala-6cdb6b0299cb917ac3df9e39aa932bacdc31faf9.zip
Merge pull request #669 from dgruntz/master
Fixes typos in scaladoc of Orderes.scala
Diffstat (limited to 'src/library')
-rw-r--r--src/library/scala/math/Ordered.scala11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/library/scala/math/Ordered.scala b/src/library/scala/math/Ordered.scala
index 80addea7f3..a5efa41b80 100644
--- a/src/library/scala/math/Ordered.scala
+++ b/src/library/scala/math/Ordered.scala
@@ -15,7 +15,7 @@ import language.implicitConversions
* more information about whether to use [[scala.math.Ordering]] instead.
*
* Classes that implement this trait can be sorted with
- * [[scala.utils.Sorting]] and can be compared with standard comparison operators
+ * [[scala.util.Sorting]] and can be compared with standard comparison operators
* (e.g. > and <).
*
* Ordered should be used for data with a single, natural ordering (like
@@ -27,14 +27,15 @@ import language.implicitConversions
*
* [[scala.math.PartiallyOrdered]] is an alternative to this trait for partially ordered data.
*
- * For example, to create a simple class that implements Ordered and then sort it with [[scala.utils.Sorting]]:
+ * For example, create a simple class that implements `Ordered` and then sort it with [[scala.util.Sorting]]:
* {{{
- * class OrderedClass(n:Int) extends Ordered[OrderedClass] {
+ * case class OrderedClass(n:Int) extends Ordered[OrderedClass] {
* def compare(that: OrderedClass) = this.n - that.n
* }
*
- * val x = List(new MyClass(1), new MyClass(5), new MyClass(3))
- * val result = scala.utils.Sorting.quickSort(x)
+ * val x = Array(OrderedClass(1), OrderedClass(5), OrderedClass(3))
+ * scala.util.Sorting.quickSort(x)
+ * x
* }}}
*
* It is important that the `equals` method for an instance of `Ordered[A]` be consistent with the