summaryrefslogtreecommitdiff
path: root/src/library/scala/Product1.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/library/scala/Product1.scala')
-rw-r--r--src/library/scala/Product1.scala6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/library/scala/Product1.scala b/src/library/scala/Product1.scala
index ab8b0a4505..d268b35f60 100644
--- a/src/library/scala/Product1.scala
+++ b/src/library/scala/Product1.scala
@@ -17,13 +17,13 @@ object Product1 {
/** Product1 is a cartesian product of 1 component.
* @since 2.3
*/
-trait Product1[@specialized(Int, Long, Double) +T1] extends Product {
+trait Product1[@specialized(Int, Long, Double) +T1] extends Any with Product {
/** The arity of this product.
* @return 1
*/
override def productArity = 1
-
+
/** Returns the n-th projection of this product if 0 < n <= productArity,
* otherwise throws an `IndexOutOfBoundsException`.
*
@@ -33,7 +33,7 @@ trait Product1[@specialized(Int, Long, Double) +T1] extends Product {
*/
@throws(classOf[IndexOutOfBoundsException])
- override def productElement(n: Int) = n match {
+ override def productElement(n: Int) = n match {
case 0 => _1
case _ => throw new IndexOutOfBoundsException(n.toString())
}