From 895280684fc63f56f5822114118b3275dac7ec5c Mon Sep 17 00:00:00 2001 From: Hubert Plociniczak Date: Wed, 13 Jan 2010 11:05:24 +0000 Subject: When comparing type aliases use info instead of... When comparing type aliases use info instead of tpe so that the changes are correctly detected. Fixes #2650. No review. --- src/compiler/scala/tools/nsc/dependencies/Changes.scala | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/compiler') diff --git a/src/compiler/scala/tools/nsc/dependencies/Changes.scala b/src/compiler/scala/tools/nsc/dependencies/Changes.scala index db0567993b..a69d4b3e86 100644 --- a/src/compiler/scala/tools/nsc/dependencies/Changes.scala +++ b/src/compiler/scala/tools/nsc/dependencies/Changes.scala @@ -166,7 +166,13 @@ abstract class Changes { else if (n == NoSymbol) cs += Removed(toEntity(o)) else { - val newSym = n.suchThat(ov => sameType(ov.tpe, o.tpe)) + val newSym = + o match { + case _:TypeSymbol if o.isAliasType => + n.suchThat(ov => sameType(ov.info, o.info)) + case _ => + n.suchThat(ov => sameType(ov.tpe, o.tpe)) + } if (newSym == NoSymbol || moreRestrictive(o.flags, newSym.flags)) cs += Changed(toEntity(o))(n + " changed from " + o.tpe + " to " + n.tpe + " flags: " + Flags.flagsToString(o.flags)) else -- cgit v1.2.3