summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/files/neg/t5106.check11
-rw-r--r--test/files/neg/t5106.scala5
2 files changed, 16 insertions, 0 deletions
diff --git a/test/files/neg/t5106.check b/test/files/neg/t5106.check
new file mode 100644
index 0000000000..ac16041cf7
--- /dev/null
+++ b/test/files/neg/t5106.check
@@ -0,0 +1,11 @@
+t5106.scala:3: error: type mismatch;
+ found : Int(4)
+ required: String
+ val (n, l): (String, Int) = (4, "")
+ ^
+t5106.scala:3: error: type mismatch;
+ found : String("")
+ required: Int
+ val (n, l): (String, Int) = (4, "")
+ ^
+two errors found
diff --git a/test/files/neg/t5106.scala b/test/files/neg/t5106.scala
new file mode 100644
index 0000000000..419b430ff1
--- /dev/null
+++ b/test/files/neg/t5106.scala
@@ -0,0 +1,5 @@
+class A {
+ def f {
+ val (n, l): (String, Int) = (4, "")
+ }
+}