aboutsummaryrefslogtreecommitdiff
path: root/compiler/src/dotty/tools/dotc/core
diff options
context:
space:
mode:
authorGuillaume Martres <smarter@ubuntu.com>2017-03-18 19:50:16 +0100
committerGitHub <noreply@github.com>2017-03-18 19:50:16 +0100
commit215c13408f7709c416baf561c513159622f10ba5 (patch)
treea186ebcfd2bc648b1e3f7cf9b58dbba57e5cd88a /compiler/src/dotty/tools/dotc/core
parent3ec16c78bd8a90f1205bb9047969ab3fd9e8dd75 (diff)
parent675892a4aaa77a4e71faa6057b4a0a059acb408d (diff)
downloaddotty-215c13408f7709c416baf561c513159622f10ba5.tar.gz
dotty-215c13408f7709c416baf561c513159622f10ba5.tar.bz2
dotty-215c13408f7709c416baf561c513159622f10ba5.zip
Merge pull request #2110 from dotty-staging/fix/reduce-more-lambdas
Reduce type lambdas even if variance changes
Diffstat (limited to 'compiler/src/dotty/tools/dotc/core')
-rw-r--r--compiler/src/dotty/tools/dotc/core/TypeApplications.scala7
1 files changed, 4 insertions, 3 deletions
diff --git a/compiler/src/dotty/tools/dotc/core/TypeApplications.scala b/compiler/src/dotty/tools/dotc/core/TypeApplications.scala
index c713cd542..ba3e6a461 100644
--- a/compiler/src/dotty/tools/dotc/core/TypeApplications.scala
+++ b/compiler/src/dotty/tools/dotc/core/TypeApplications.scala
@@ -1,4 +1,5 @@
-package dotty.tools.dotc
+package dotty.tools
+package dotc
package core
import Types._
@@ -412,8 +413,8 @@ class TypeApplications(val self: Type) extends AnyVal {
val followAlias = Config.simplifyApplications && {
dealiased.resType match {
case AppliedType(tyconBody, _) =>
- variancesConform(typParams, tyconBody.typeParams)
- // Reducing is safe for type inference, as kind of type constructor does not change
+ sameLength(dealiased.typeParams, tyconBody.typeParams)
+ // Reducing is safe for type inference, as kind arity of type constructor does not change
case _ => false
}
}