From a4f35e2cf41dd38a35688f351510603165c6f89f Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Sat, 16 Jan 2016 13:00:46 +0100 Subject: Make skolems uncached There was no reason in the first case to cache them, as their equality is reference identity. Maybe this fixes the OOM errors we encounter. --- src/dotty/tools/dotc/core/Types.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/dotty/tools/dotc/core/Types.scala') diff --git a/src/dotty/tools/dotc/core/Types.scala b/src/dotty/tools/dotc/core/Types.scala index 45897dd64..84602ccf7 100644 --- a/src/dotty/tools/dotc/core/Types.scala +++ b/src/dotty/tools/dotc/core/Types.scala @@ -2506,11 +2506,11 @@ object Types { // ----- Skolem types ----------------------------------------------- /** A skolem type reference with underlying type `binder`. */ - abstract case class SkolemType(info: Type) extends CachedProxyType with ValueType with SingletonType { + abstract case class SkolemType(info: Type) extends UncachedProxyType with ValueType with SingletonType { override def underlying(implicit ctx: Context) = info def derivedSkolemType(info: Type)(implicit ctx: Context) = if (info eq this.info) this else SkolemType(info) - override def computeHash: Int = identityHash + override def hashCode: Int = identityHash override def equals(that: Any) = this eq that.asInstanceOf[AnyRef] override def toString = s"Skolem($info)" } -- cgit v1.2.3