IR: always update deserializedSymbols in referenceLocalIrSymbol
The symbol created in deserializeIrSymbolToDeclare might be discarded when an existing declaration is used in deserialization (as it happens when deserializing IR bodies for JVM declarations).
This commit is contained in:
committed by
TeamCityServer
parent
eccbf38061
commit
307de0be89
+1
-1
@@ -286,7 +286,7 @@ class IrDeclarationDeserializer(
|
||||
|
||||
// make sure this symbol is known to linker
|
||||
symbolDeserializer.referenceLocalIrSymbol(result.symbol, sig)
|
||||
result.annotations += deserializeAnnotations(proto.base.annotationList)
|
||||
result.annotations = deserializeAnnotations(proto.base.annotationList)
|
||||
result.parent = currentParent
|
||||
return result
|
||||
}
|
||||
|
||||
+1
-1
@@ -73,7 +73,7 @@ class IrSymbolDeserializer(
|
||||
}
|
||||
|
||||
fun referenceLocalIrSymbol(symbol: IrSymbol, signature: IdSignature) {
|
||||
deserializedSymbols.putIfAbsent(signature, symbol)
|
||||
deserializedSymbols.put(signature, symbol)
|
||||
}
|
||||
|
||||
fun referenceSimpleFunctionByLocalSignature(idSignature: IdSignature) : IrSimpleFunctionSymbol =
|
||||
|
||||
Reference in New Issue
Block a user