diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2014-05-27 15:36:59 +0200 |
---|---|---|
committer | Jason Zaugg <jzaugg@gmail.com> | 2014-05-27 15:36:59 +0200 |
commit | 159bade707f006a10745f58871806400b6a76166 (patch) | |
tree | 1da22429ac397ef97ac7a6c7e89c81deedd529b0 /test/files | |
parent | ae6724527d2798b49e9c2cede536af48b3c9d962 (diff) | |
parent | 33446bd6f311a2bd5e565382836327fe5d337df7 (diff) | |
download | scala-159bade707f006a10745f58871806400b6a76166.tar.gz scala-159bade707f006a10745f58871806400b6a76166.tar.bz2 scala-159bade707f006a10745f58871806400b6a76166.zip |
Merge pull request #3782 from retronym/topic/opt-scope
Compiler optimizations for Scopes, checkDoubleDefs, Namer
Diffstat (limited to 'test/files')
-rw-r--r-- | test/files/neg/double-def-top-level.check | 7 | ||||
-rw-r--r-- | test/files/neg/double-def-top-level/A_1.scala | 4 | ||||
-rw-r--r-- | test/files/neg/double-def-top-level/B_2.scala | 2 | ||||
-rw-r--r-- | test/files/neg/double-def-top-level/C_3.scala | 2 | ||||
-rw-r--r-- | test/files/neg/double-def-top-level/D_3.scala | 2 |
5 files changed, 17 insertions, 0 deletions
diff --git a/test/files/neg/double-def-top-level.check b/test/files/neg/double-def-top-level.check new file mode 100644 index 0000000000..85b16e81e5 --- /dev/null +++ b/test/files/neg/double-def-top-level.check @@ -0,0 +1,7 @@ +D_3.scala:1: error: C is already defined as class C +class C + ^ +D_3.scala:2: error: O is already defined as object O +object O + ^ +two errors found diff --git a/test/files/neg/double-def-top-level/A_1.scala b/test/files/neg/double-def-top-level/A_1.scala new file mode 100644 index 0000000000..c3d68d9d05 --- /dev/null +++ b/test/files/neg/double-def-top-level/A_1.scala @@ -0,0 +1,4 @@ +package p + +class C +object O diff --git a/test/files/neg/double-def-top-level/B_2.scala b/test/files/neg/double-def-top-level/B_2.scala new file mode 100644 index 0000000000..c328e8c964 --- /dev/null +++ b/test/files/neg/double-def-top-level/B_2.scala @@ -0,0 +1,2 @@ +class C /* noerror */ +object O /* noerror */
\ No newline at end of file diff --git a/test/files/neg/double-def-top-level/C_3.scala b/test/files/neg/double-def-top-level/C_3.scala new file mode 100644 index 0000000000..e1c327c15a --- /dev/null +++ b/test/files/neg/double-def-top-level/C_3.scala @@ -0,0 +1,2 @@ +class C +object O
\ No newline at end of file diff --git a/test/files/neg/double-def-top-level/D_3.scala b/test/files/neg/double-def-top-level/D_3.scala new file mode 100644 index 0000000000..518e0d1c54 --- /dev/null +++ b/test/files/neg/double-def-top-level/D_3.scala @@ -0,0 +1,2 @@ +class C +object O |