diff options
author | Lukas Rytz <lukas.rytz@epfl.ch> | 2009-05-30 07:36:31 +0000 |
---|---|---|
committer | Lukas Rytz <lukas.rytz@epfl.ch> | 2009-05-30 07:36:31 +0000 |
commit | 390ccacfe0caa4c07af6193dec3e172c0fcd7896 (patch) | |
tree | 001ff4a00bd9d8cab651d9bf245bfc795748d829 /test/files/pos | |
parent | 661f1ba10e5062fd987c4cafe43ad1f0dc3f5491 (diff) | |
download | scala-390ccacfe0caa4c07af6193dec3e172c0fcd7896.tar.gz scala-390ccacfe0caa4c07af6193dec3e172c0fcd7896.tar.bz2 scala-390ccacfe0caa4c07af6193dec3e172c0fcd7896.zip |
Named and default arguments
- MethodTypes now have (params: List[Symbol])
- "copy"-methods for case classes
- the "copy" object in the compiler is now called "treeCopy"
Diffstat (limited to 'test/files/pos')
-rw-r--r-- | test/files/pos/t1659.check | 5 | ||||
-rw-r--r-- | test/files/pos/t1659.scala | 4 |
2 files changed, 9 insertions, 0 deletions
diff --git a/test/files/pos/t1659.check b/test/files/pos/t1659.check new file mode 100644 index 0000000000..b75da8798b --- /dev/null +++ b/test/files/pos/t1659.check @@ -0,0 +1,5 @@ +t1659.scala:3: error: overriding method u in trait W of type [A](v: Y{type X = A})Unit; + method u has incompatible type +class Z extends W { def u[A](v : Y { type X = A }) = null } + ^ +one error found diff --git a/test/files/pos/t1659.scala b/test/files/pos/t1659.scala new file mode 100644 index 0000000000..10470d66f8 --- /dev/null +++ b/test/files/pos/t1659.scala @@ -0,0 +1,4 @@ +trait Y { type X } +trait W { def u[A](v : Y { type X = A }) : Unit } +class Z extends W { def u[A](v : Y { type X = A }) = null } + |