summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/files/run/t6646.check3
-rw-r--r--test/files/run/t6646.scala13
2 files changed, 16 insertions, 0 deletions
diff --git a/test/files/run/t6646.check b/test/files/run/t6646.check
new file mode 100644
index 0000000000..e27b5b9efb
--- /dev/null
+++ b/test/files/run/t6646.check
@@ -0,0 +1,3 @@
+Found NotNull
+Found lower
+Found 2
diff --git a/test/files/run/t6646.scala b/test/files/run/t6646.scala
new file mode 100644
index 0000000000..9418bfafb1
--- /dev/null
+++ b/test/files/run/t6646.scala
@@ -0,0 +1,13 @@
+sealed trait ColumnOption
+case object NotNull extends ColumnOption
+case object PrimaryKey extends ColumnOption
+case object lower extends ColumnOption
+
+object Test {
+ def main(args: Array[String]) {
+ val l = List(PrimaryKey, NotNull, lower)
+ for (option @ NotNull <- l) println("Found " + option)
+ for (option @ `lower` <- l) println("Found " + option)
+ for ((`lower`, i) <- l.zipWithIndex) println("Found " + i)
+ }
+}