diff options
author | Martin Odersky <odersky@gmail.com> | 2014-03-16 21:39:18 +0100 |
---|---|---|
committer | Tobias Schlatter <tobias@meisch.ch> | 2014-03-21 11:24:04 +0100 |
commit | 7bf837c79315e5db7e049f3ffeb6c6842d18880c (patch) | |
tree | fc74ac3f158adeba356fbca9d0d0df91d894c3d8 /tests/pos | |
parent | 2c2ab10958e27ced276c9906f18a67c1eddd1928 (diff) | |
download | dotty-7bf837c79315e5db7e049f3ffeb6c6842d18880c.tar.gz dotty-7bf837c79315e5db7e049f3ffeb6c6842d18880c.tar.bz2 dotty-7bf837c79315e5db7e049f3ffeb6c6842d18880c.zip |
Fix of t0774: empty file
Was previously wrapped in a
package <empty>
but the resulting tree had no position, which caused a Typer assertion. If now
represented as EmptyTree.
Diffstat (limited to 'tests/pos')
-rw-r--r-- | tests/pos/t0612/C.scala | 6 | ||||
-rw-r--r-- | tests/pos/t0612/Ob.scala | 5 | ||||
-rw-r--r-- | tests/pos/t0774/deathname.scala | 1 | ||||
-rw-r--r-- | tests/pos/t0774/unrelated.scala | 9 |
4 files changed, 21 insertions, 0 deletions
diff --git a/tests/pos/t0612/C.scala b/tests/pos/t0612/C.scala new file mode 100644 index 000000000..1f260a5b0 --- /dev/null +++ b/tests/pos/t0612/C.scala @@ -0,0 +1,6 @@ +package test +package app + +class C { + Ob.f +} diff --git a/tests/pos/t0612/Ob.scala b/tests/pos/t0612/Ob.scala new file mode 100644 index 000000000..d12e64963 --- /dev/null +++ b/tests/pos/t0612/Ob.scala @@ -0,0 +1,5 @@ +package test + +object Ob { + protected[test] def f: Unit = {} +} diff --git a/tests/pos/t0774/deathname.scala b/tests/pos/t0774/deathname.scala new file mode 100644 index 000000000..8b1378917 --- /dev/null +++ b/tests/pos/t0774/deathname.scala @@ -0,0 +1 @@ + diff --git a/tests/pos/t0774/unrelated.scala b/tests/pos/t0774/unrelated.scala new file mode 100644 index 000000000..1efdb2505 --- /dev/null +++ b/tests/pos/t0774/unrelated.scala @@ -0,0 +1,9 @@ +object Outer { + import Inner._ + + deathname + + object Inner { + def deathname: Int = 1 + } +} |