aboutsummaryrefslogtreecommitdiff
path: root/tests/neg
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2017-02-02 13:47:45 +1100
committerMartin Odersky <odersky@gmail.com>2017-02-02 13:49:54 +1100
commit4585dcbaeb75df072f1a50ea6b7a9cb3fcfad4ee (patch)
treeaac7bc4e5fe6fc239a5e1fd6b239751eae126281 /tests/neg
parent64332a794c05cbf21491eaf0bfdf4482a80b1b10 (diff)
downloaddotty-4585dcbaeb75df072f1a50ea6b7a9cb3fcfad4ee.tar.gz
dotty-4585dcbaeb75df072f1a50ea6b7a9cb3fcfad4ee.tar.bz2
dotty-4585dcbaeb75df072f1a50ea6b7a9cb3fcfad4ee.zip
Fix #1568 - avoid transforming error trees
If a tree has type error, subtrees may not have an assigned type. Therefore we should avoid transforming such trees.
Diffstat (limited to 'tests/neg')
-rw-r--r--tests/neg/i1568.scala3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/neg/i1568.scala b/tests/neg/i1568.scala
new file mode 100644
index 000000000..a260c530b
--- /dev/null
+++ b/tests/neg/i1568.scala
@@ -0,0 +1,3 @@
+object Test {
+ inline def foo(n: Int) = foo(n) // error: cyclic reference
+}