summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2007-01-31 15:41:15 +0000
committerMartin Odersky <odersky@gmail.com>2007-01-31 15:41:15 +0000
commit485a79aa79142c2740a64f8e7a83036067c7ee9c (patch)
treeec7b727adab3da022e61ddff8692b118333e1cb6 /test
parente566c7126ce2a593e9d5711784667a25bc92d514 (diff)
downloadscala-485a79aa79142c2740a64f8e7a83036067c7ee9c.tar.gz
scala-485a79aa79142c2740a64f8e7a83036067c7ee9c.tar.bz2
scala-485a79aa79142c2740a64f8e7a83036067c7ee9c.zip
made pattern constructors termsymbols
Diffstat (limited to 'test')
-rw-r--r--test/files/neg/scopes.check5
-rw-r--r--test/files/run/bug920.check1
-rw-r--r--test/files/run/bug920.scala20
3 files changed, 22 insertions, 4 deletions
diff --git a/test/files/neg/scopes.check b/test/files/neg/scopes.check
index 09b1bcbdb6..ca32035316 100644
--- a/test/files/neg/scopes.check
+++ b/test/files/neg/scopes.check
@@ -1,9 +1,6 @@
scopes.scala:1: error: x is already defined as value x
case class test0(x: int, x: float)
^
-scopes.scala:2: error: x is already defined as value x
-
-^
scopes.scala:5: error: t is already defined as type t
type t = float
^
@@ -25,4 +22,4 @@ scopes.scala:15: error: x is already defined as value x
scopes.scala:17: error: x is already defined as value x
case x::x => x
^
-9 errors found
+8 errors found
diff --git a/test/files/run/bug920.check b/test/files/run/bug920.check
new file mode 100644
index 0000000000..76018072e0
--- /dev/null
+++ b/test/files/run/bug920.check
@@ -0,0 +1 @@
+baz
diff --git a/test/files/run/bug920.scala b/test/files/run/bug920.scala
new file mode 100644
index 0000000000..6a7f122d55
--- /dev/null
+++ b/test/files/run/bug920.scala
@@ -0,0 +1,20 @@
+object Test {
+ trait A;
+ trait Foo0 { def foo : A; }
+ trait Baz extends Foo0;
+ trait B extends A {
+ def initialize = {
+ trait Foo extends Test.Foo0 {
+ def foo : B.this.type = B.this;
+ }
+ class baz extends Baz with Foo {
+ override def toString = "baz"
+ }
+ Console.println(new baz);
+ }
+ }
+ object b extends B;
+ def main(args : Array[String]) : Unit = {
+ b.initialize;
+ }
+}