summaryrefslogtreecommitdiff
path: root/test/files/pos/bug217.scala
diff options
context:
space:
mode:
Diffstat (limited to 'test/files/pos/bug217.scala')
-rw-r--r--test/files/pos/bug217.scala13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/files/pos/bug217.scala b/test/files/pos/bug217.scala
new file mode 100644
index 0000000000..15a9f16a1b
--- /dev/null
+++ b/test/files/pos/bug217.scala
@@ -0,0 +1,13 @@
+object Test {
+
+ def foo[t](fun: Function0[t]): t = fun();
+
+ def bar(x: Int): Unit = {
+ foo(() => 0);
+ ()
+ }
+
+ def main(args: Array[String]): Unit = bar(32);
+
+}
+