diff options
author | Adriaan Moors <adriaan.moors@epfl.ch> | 2007-08-20 22:04:34 +0000 |
---|---|---|
committer | Adriaan Moors <adriaan.moors@epfl.ch> | 2007-08-20 22:04:34 +0000 |
commit | f8b2b21050e7a2ca0f537ef70e3e0c8eead43abc (patch) | |
tree | 108dab0bcef5917662e29b62ca9deb0ced05f415 /test | |
parent | f69c8e975a7b5eee1566c63f9732a38a3f253407 (diff) | |
download | scala-f8b2b21050e7a2ca0f537ef70e3e0c8eead43abc.tar.gz scala-f8b2b21050e7a2ca0f537ef70e3e0c8eead43abc.tar.bz2 scala-f8b2b21050e7a2ca0f537ef70e3e0c8eead43abc.zip |
Martin: please review
fixed 1210 for real (I hope), fix is in mapOver in Types.scala Also in
this commit: small fix to `undoTo` (added check that log is not empty)
Diffstat (limited to 'test')
-rwxr-xr-x | test/files/pos/bug1210a.scala | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/test/files/pos/bug1210a.scala b/test/files/pos/bug1210a.scala index a349a26753..7daf7f1179 100755 --- a/test/files/pos/bug1210a.scala +++ b/test/files/pos/bug1210a.scala @@ -1,9 +1,15 @@ -object Test { - def id[T](f: T => T): T = error("bla") +// both styles of abstraction should behave the same +// related to 1210 because that bug broke the OO version below +trait OO { + abstract class Test { self => + type T - abstract class M[Settings] { - type selfType = M[Settings] - - val v: selfType = id[M.this.selfType](x => x.v) + val v: Test {type T = self.T} = self.v.v } } + +trait FP { + abstract class Test[T] { + val v: Test[T] = v.v + } +}
\ No newline at end of file |