aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorGuillaume Martres <smarter@ubuntu.com>2017-03-28 18:20:18 +0200
committerGitHub <noreply@github.com>2017-03-28 18:20:18 +0200
commit9ba9b147fb8d7894761e2f2fb18b08601981db20 (patch)
tree0b8b34b9bbdeee0591c10f55f7e43b7d0d0ac02b /tests
parentd9dedc5ac6690fa724271be33550e77696e193cb (diff)
parentb6411818b2e84c0a28c501e2814de4cfde720208 (diff)
downloaddotty-9ba9b147fb8d7894761e2f2fb18b08601981db20.tar.gz
dotty-9ba9b147fb8d7894761e2f2fb18b08601981db20.tar.bz2
dotty-9ba9b147fb8d7894761e2f2fb18b08601981db20.zip
Merge pull request #2139 from dotty-staging/fix/false-companion
Fix #2137: Create dummy companions for top-level objects without a real one
Diffstat (limited to 'tests')
-rw-r--r--tests/pending/pos/false-companion/00_outerinnerTest_2.scala5
-rw-r--r--tests/pending/pos/false-companion/01_outerinnerFoo_2.scala5
-rw-r--r--tests/pending/pos/false-companion/outerFoo_1.scala2
-rw-r--r--tests/pending/pos/false-companion/outerinnerFoo_1.scala5
4 files changed, 17 insertions, 0 deletions
diff --git a/tests/pending/pos/false-companion/00_outerinnerTest_2.scala b/tests/pending/pos/false-companion/00_outerinnerTest_2.scala
new file mode 100644
index 000000000..8f5802343
--- /dev/null
+++ b/tests/pending/pos/false-companion/00_outerinnerTest_2.scala
@@ -0,0 +1,5 @@
+package outer
+package inner
+object Test {
+ val x: Foo = new Foo
+}
diff --git a/tests/pending/pos/false-companion/01_outerinnerFoo_2.scala b/tests/pending/pos/false-companion/01_outerinnerFoo_2.scala
new file mode 100644
index 000000000..111f7fcd5
--- /dev/null
+++ b/tests/pending/pos/false-companion/01_outerinnerFoo_2.scala
@@ -0,0 +1,5 @@
+package outer
+package inner
+object Foo {
+ // val a: Int = 1
+}
diff --git a/tests/pending/pos/false-companion/outerFoo_1.scala b/tests/pending/pos/false-companion/outerFoo_1.scala
new file mode 100644
index 000000000..8c2ef109c
--- /dev/null
+++ b/tests/pending/pos/false-companion/outerFoo_1.scala
@@ -0,0 +1,2 @@
+package outer
+class Foo
diff --git a/tests/pending/pos/false-companion/outerinnerFoo_1.scala b/tests/pending/pos/false-companion/outerinnerFoo_1.scala
new file mode 100644
index 000000000..29f3df724
--- /dev/null
+++ b/tests/pending/pos/false-companion/outerinnerFoo_1.scala
@@ -0,0 +1,5 @@
+package outer
+package inner
+object Foo {
+ val a: Int = 1
+}