IR: Fix missing source in IrClass with DeepCopyIrTreeWithSymbols

When using DeepCopyIrTreeWithSymbols as class transformer to transform
the IrClass, the source element of IrClass was set to
SourceElement.NO_SOURCE after the transform.

^KT-65343 Fixed
This commit is contained in:
xiaozihan.larryxiao
2024-01-27 00:22:58 +08:00
committed by Space Team
parent 7924573d20
commit cabd9ad1ec
@@ -163,6 +163,7 @@ open class DeepCopyIrTreeWithSymbols(
isExpect = declaration.isExpect,
isFun = declaration.isFun,
hasEnumEntries = declaration.hasEnumEntries,
source = declaration.source,
).apply {
transformAnnotations(declaration)
copyTypeParametersFrom(declaration)