aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorNicolas Stucki <nicolas.stucki@gmail.com>2017-02-21 14:26:27 +0100
committerGitHub <noreply@github.com>2017-02-21 14:26:27 +0100
commit61858c048bacb22aeab1893f8812896cb2b4d6a7 (patch)
tree50d46c289d7cc12ff840e9f1632770f46f6d1d65 /tests
parent9f879c1677b467037f6c19cc0abe43e0adb802fa (diff)
parent5f9e569926728e7f591a26729efa7700387aeb22 (diff)
downloaddotty-61858c048bacb22aeab1893f8812896cb2b4d6a7.tar.gz
dotty-61858c048bacb22aeab1893f8812896cb2b4d6a7.tar.bz2
dotty-61858c048bacb22aeab1893f8812896cb2b4d6a7.zip
Merge pull request #2013 from dotty-staging/fix-#2006
Don't inline when errors are detected
Diffstat (limited to 'tests')
-rw-r--r--tests/neg/i2006.scala10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/neg/i2006.scala b/tests/neg/i2006.scala
new file mode 100644
index 000000000..f1b48b011
--- /dev/null
+++ b/tests/neg/i2006.scala
@@ -0,0 +1,10 @@
+object Test {
+
+ inline def foo(f: ImplicitFunction1[Int, Int]): AnyRef = f // error
+ inline def bar(f: ImplicitFunction1[Int, Int]) = f // error
+
+ def main(args: Array[String]) = {
+ foo(implicit thisTransaction => 43)
+ bar(implicit thisTransaction => 44)
+ }
+}