diff options
author | Paul Phillips <paulp@improving.org> | 2013-06-15 14:28:23 -0400 |
---|---|---|
committer | Simon Ochsenreither <simon@ochsenreither.de> | 2013-07-17 22:28:14 +0200 |
commit | aeb733147881d8da68d1e520b14112dc826a3977 (patch) | |
tree | f5a934ae4eb223ba4db591a2d3fac3d9407759d9 /test/files/neg/t1432.scala | |
parent | 9761d2286848173b4cc90a0f28d9e6ea0f3248cf (diff) | |
download | scala-aeb733147881d8da68d1e520b14112dc826a3977.tar.gz scala-aeb733147881d8da68d1e520b14112dc826a3977.tar.bz2 scala-aeb733147881d8da68d1e520b14112dc826a3977.zip |
Cleanups in type printing.
More consistency as to how to understand aliases,
singletons, specialized symbols, subclasses. Fewer
weird special casings, like normalizing tuples
and functions during type printing, but nothing else.
I avoid "normalize" entirely now, and do not make
special cases for dealiasing, which is already well
handled when printing error messages.
Look at the change to test/files/neg/t2641.check to get
a sense of why we should resist calling normalize during
the early days of a compilation run.
Anonymous and refinement classes can be printed far more
usefully by revealing their parents, and that too is here.
Hardened toString against undesirable side effects.
Make toString final to discourage any further rogue
toString overriders. Make safeToString a little safer.
Diffstat (limited to 'test/files/neg/t1432.scala')
-rw-r--r-- | test/files/neg/t1432.scala | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/files/neg/t1432.scala b/test/files/neg/t1432.scala index 638f36554f..bdf2331280 100644 --- a/test/files/neg/t1432.scala +++ b/test/files/neg/t1432.scala @@ -4,7 +4,9 @@ object Bug_NoUnique { case class Wrap[E](parent:E) {} - def wrap[E,A,Y](v : (A,E=>Y)) : (A,Wrap[E]=>Y) = + type Alias2[E] = Wrap[E] + + def wrap[E,A,Y](v : (A,E=>Y)) : (A,Alias2[E]=>Y) = throw new Error("Body here") def test(x : TypeCon[Wrap[Unit]]) : TypeCon[Unit] = wrap(x) |