diff options
Diffstat (limited to 'test/pos/bug217.scala')
-rw-r--r-- | test/pos/bug217.scala | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/pos/bug217.scala b/test/pos/bug217.scala new file mode 100644 index 0000000000..15a9f16a1b --- /dev/null +++ b/test/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); + +} + |