From eafea736382928cdb8f3abf513f63b6eceb99db4 Mon Sep 17 00:00:00 2001 From: Alexander Udalov Date: Fri, 25 Dec 2015 19:31:45 +0300 Subject: [PATCH] Mark enum entry names as name ids for incremental compilation purposes Original commit: 697228eae0c7de10f1dcc5b27400cca07b8d8dfd --- .../jetbrains/kotlin/jps/incremental/ProtoCompareGenerated.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jps/jps-plugin/src/org/jetbrains/kotlin/jps/incremental/ProtoCompareGenerated.kt b/jps/jps-plugin/src/org/jetbrains/kotlin/jps/incremental/ProtoCompareGenerated.kt index 9dd6ea9ef24..b35449f5e86 100644 --- a/jps/jps-plugin/src/org/jetbrains/kotlin/jps/incremental/ProtoCompareGenerated.kt +++ b/jps/jps-plugin/src/org/jetbrains/kotlin/jps/incremental/ProtoCompareGenerated.kt @@ -388,7 +388,7 @@ open class ProtoCompareGenerated(public val oldNameResolver: NameResolver, publi open fun checkEquals(old: ProtoBuf.EnumEntry, new: ProtoBuf.EnumEntry): Boolean { if (old.hasName() != new.hasName()) return false if (old.hasName()) { - if (old.name != new.name) return false + if (!checkStringEquals(old.name, new.name)) return false } return true @@ -1075,7 +1075,7 @@ public fun ProtoBuf.EnumEntry.hashCode(stringIndexes: (Int) -> Int, fqNameIndexe var hashCode = 1 if (hasName()) { - hashCode = 31 * hashCode + name + hashCode = 31 * hashCode + stringIndexes(name) } return hashCode