From cfa250957ad01732d2963273e935762005be6c2c Mon Sep 17 00:00:00 2001 From: Dmitriy Novozhilov Date: Mon, 29 Jun 2020 14:45:53 +0300 Subject: [PATCH] [FIR] Fix creating type attributes for intersection types --- .../fir/cones/src/org/jetbrains/kotlin/fir/types/ConeTypes.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/fir/cones/src/org/jetbrains/kotlin/fir/types/ConeTypes.kt b/compiler/fir/cones/src/org/jetbrains/kotlin/fir/types/ConeTypes.kt index f2e63c6a50a..2d1f0e0d2d4 100644 --- a/compiler/fir/cones/src/org/jetbrains/kotlin/fir/types/ConeTypes.kt +++ b/compiler/fir/cones/src/org/jetbrains/kotlin/fir/types/ConeTypes.kt @@ -243,7 +243,7 @@ class ConeIntersectionType( override val attributes: ConeAttributes = intersectedTypes.foldMap( { it.attributes }, - { a, b -> a.union(b) } + { a, b -> a.intersect(b) } ) private var hashCode = 0