From 7eb6f102e8e3bf90319e0339938d7e6eb5aaea43 Mon Sep 17 00:00:00 2001 From: Paul Phillips Date: Fri, 18 Nov 2011 22:23:08 +0000 Subject: Fix for unfortunate thinko recently introduced. Many thanks to Jordi Salvat i Alabart for catching this. Universal equality is a formidable foe when it comes to avoiding this kind of mistake. Closes SI-5206, no review. --- src/compiler/scala/reflect/internal/Types.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/compiler/scala/reflect/internal/Types.scala b/src/compiler/scala/reflect/internal/Types.scala index c8d7cb3a1e..7322eec1df 100644 --- a/src/compiler/scala/reflect/internal/Types.scala +++ b/src/compiler/scala/reflect/internal/Types.scala @@ -2916,7 +2916,7 @@ A type's typeSymbol should never be inspected directly. // Optimization to avoid creating unnecessary new typerefs. def copyTypeRef(tp: Type, pre: Type, sym: Symbol, args: List[Type]): Type = tp match { - case TypeRef(pre0, sym0, _) if (pre0 eq sym0) && sym0.name == sym.name => + case TypeRef(pre0, sym0, _) if pre == pre0 && sym0.name == sym.name => if (sym.isAliasType && sameLength(sym.info.typeParams, args) && !sym.lockOK) throw new TypeError("illegal cyclic reference involving " + sym) -- cgit v1.2.3