diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2013-11-24 22:25:28 +0100 |
---|---|---|
committer | Jason Zaugg <jzaugg@gmail.com> | 2013-11-26 17:17:21 +0100 |
commit | 51cd47491e979b10b5d86992dd2e3efd08f7e214 (patch) | |
tree | 773fbd35c1be49a13437214fff23c5e2d80d929c /test/files/pos | |
parent | 2ce7b1269aebcc83ee433f4114779e54ee43f9f3 (diff) | |
download | scala-51cd47491e979b10b5d86992dd2e3efd08f7e214.tar.gz scala-51cd47491e979b10b5d86992dd2e3efd08f7e214.tar.bz2 scala-51cd47491e979b10b5d86992dd2e3efd08f7e214.zip |
Removes Gen*View and Par*View
- code that used to be inherited in *View is now inlined
- the `view` methods on `ParIteratoa` and `ParSeq` now
convert to sequential collections, and are deprecated
asking the user to do this explicitly in the future.
Should be largely source compatible with 2.10.x, on the assumption
that the removed classes, while being public, were internal
implementation details.
A few tests used now-removed classes to demonstrate compiler crashes.
I managed to confirm that after my decoupling, t4365 still exercises
the bug:
% qbin/scalac test/files/pos/t4365/*.scala
warning: there were 2 deprecation warning(s); re-run with -deprecation for details
one warning found
% scalac-hash 7b4e450 test/files/pos/t4365/*.scala
warning: there were 2 deprecation warning(s); re-run with -deprecation for details
one warning found
% scalac-hash 7b4e450~1 test/files/pos/t4365/*.scala 2<&1 | grep -i wrong
error: something is wrong: cannot make sense of type application
something is wrong: cannot make sense of type application
something is wrong: cannot make sense of type application
I didn't manage to do the same for specializes-sym-crash.scala,
and instead just made it compile.
Diffstat (limited to 'test/files/pos')
-rw-r--r-- | test/files/pos/specializes-sym-crash.scala | 6 | ||||
-rw-r--r-- | test/files/pos/t4365/a_1.scala | 4 | ||||
-rw-r--r-- | test/files/pos/t4365/b_1.scala | 6 |
3 files changed, 9 insertions, 7 deletions
diff --git a/test/files/pos/specializes-sym-crash.scala b/test/files/pos/specializes-sym-crash.scala index c46f435ac4..7778ba277b 100644 --- a/test/files/pos/specializes-sym-crash.scala +++ b/test/files/pos/specializes-sym-crash.scala @@ -2,11 +2,11 @@ import scala.collection._ trait Foo[+A, +Coll, - +This <: GenSeqView[A, Coll] with GenSeqViewLike[A, Coll, This]] -extends GenSeq[A] with GenSeqLike[A, This] with GenIterableView[A, Coll] with GenIterableViewLike[A, Coll, This] { + +This <: SeqView[A, Coll] with SeqViewLike[A, Coll, This]] +extends Seq[A] with SeqLike[A, This] with IterableView[A, Coll] with IterableViewLike[A, Coll, This] { self => - trait Transformed[+B] extends GenSeqView[B, Coll] with super.Transformed[B] { + trait Transformed[+B] extends SeqView[B, Coll] with super.Transformed[B] { def length: Int def apply(idx: Int): B override def toString = viewToString diff --git a/test/files/pos/t4365/a_1.scala b/test/files/pos/t4365/a_1.scala index 6f3405b1ff..a24b57772d 100644 --- a/test/files/pos/t4365/a_1.scala +++ b/test/files/pos/t4365/a_1.scala @@ -2,8 +2,8 @@ import scala.collection._ trait SeqViewLike[+A, +Coll, - +This <: SeqView[A, Coll] with SeqViewLike[A, Coll, This]] - extends Seq[A] with GenSeqViewLike[A, Coll, This] + +This <: SeqView[A, Coll] with SeqViewLike[A, Coll, Nothing]] + extends Seq[A] with GenSeqViewLike[A, Coll, Nothing] { trait Transformed[+B] extends super[GenSeqViewLike].Transformed[B] diff --git a/test/files/pos/t4365/b_1.scala b/test/files/pos/t4365/b_1.scala index e5b5687185..e1423813f1 100644 --- a/test/files/pos/t4365/b_1.scala +++ b/test/files/pos/t4365/b_1.scala @@ -1,9 +1,11 @@ import scala.collection._ +trait GenSeqView0[+A, +Coll] + trait GenSeqViewLike[+A, +Coll, - +This <: GenSeqView[A, Coll] with GenSeqViewLike[A, Coll, This]] -extends GenSeq[A] { + +This <: GenSeqView0[A, Coll] with GenSeqViewLike[A, Coll, Nothing]] +extends GenSeq[A] { self => trait Transformed[+B] { |