summaryrefslogtreecommitdiff
path: root/test/files
diff options
context:
space:
mode:
Diffstat (limited to 'test/files')
-rw-r--r--test/files/neg/t5358.check7
-rw-r--r--test/files/neg/t5358.scala4
2 files changed, 11 insertions, 0 deletions
diff --git a/test/files/neg/t5358.check b/test/files/neg/t5358.check
new file mode 100644
index 0000000000..59e83bba2f
--- /dev/null
+++ b/test/files/neg/t5358.check
@@ -0,0 +1,7 @@
+t5358.scala:3: error: class C inherits conflicting members:
+ method hi in trait A of type => String and
+ method hi in trait B of type => String
+(Note: this can be resolved by declaring an override in class C.)
+class C extends A with B
+ ^
+one error found
diff --git a/test/files/neg/t5358.scala b/test/files/neg/t5358.scala
new file mode 100644
index 0000000000..13d827ed82
--- /dev/null
+++ b/test/files/neg/t5358.scala
@@ -0,0 +1,4 @@
+trait A { def hi = "A" }
+trait B { def hi = "B" }
+class C extends A with B
+