diff options
author | Martin Odersky <odersky@gmail.com> | 2008-02-26 09:50:05 +0000 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2008-02-26 09:50:05 +0000 |
commit | e869cd34104701f8c55e19c542775679a1802edd (patch) | |
tree | 80f752abc7cd116a489fdc4a9b707fa7352761da /test/files/run/t0528.scala | |
parent | bcbeab74566f835219dabf0bbb172fd028a8a032 (diff) | |
download | scala-e869cd34104701f8c55e19c542775679a1802edd.tar.gz scala-e869cd34104701f8c55e19c542775679a1802edd.tar.bz2 scala-e869cd34104701f8c55e19c542775679a1802edd.zip |
fixed #520, #489
Diffstat (limited to 'test/files/run/t0528.scala')
-rw-r--r-- | test/files/run/t0528.scala | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/files/run/t0528.scala b/test/files/run/t0528.scala new file mode 100644 index 0000000000..b00ef4fa92 --- /dev/null +++ b/test/files/run/t0528.scala @@ -0,0 +1,14 @@ +trait Sequ[A] { + def toArray: Array[T forSome {type T <: A}] +} + +class RichStr extends Sequ[Char] { + // override to a primitve array + def toArray: Array[Char] = Array('0', '1', '2', '3', '4', '5', '6', '7', '8', '9') +} + +object Test extends Application { + val x: RichStr = new RichStr + + println((x: Sequ[Char]).toArray) // calling through the bridge misses unboxing +} |