aboutsummaryrefslogtreecommitdiff
path: root/tests/pos/t2260.scala
diff options
context:
space:
mode:
Diffstat (limited to 'tests/pos/t2260.scala')
-rw-r--r--tests/pos/t2260.scala10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/pos/t2260.scala b/tests/pos/t2260.scala
new file mode 100644
index 000000000..4e4cc5ab2
--- /dev/null
+++ b/tests/pos/t2260.scala
@@ -0,0 +1,10 @@
+package top
+
+class Text(val value: String) extends Ordered[Text] {
+ def compare(that: Text) = value.compare(that.value)
+}
+
+object Index {
+ import scala.collection.immutable.TreeMap
+ val tree = TreeMap.empty[Text, String]
+}