IR: make DescriptorMetadataSource a subtype of MetadataSource

FirMetadataSource is a metadata source too.
This commit is contained in:
pyos
2020-09-15 13:43:21 +02:00
committed by Alexander Udalov
parent 86cc5840ed
commit a06181771f
18 changed files with 83 additions and 106 deletions
@@ -123,7 +123,7 @@ class ParcelableIrTransformer(private val context: IrPluginContext, private val
irExprBody(irInt(flags))
}
metadata = MetadataSource.Function(
metadata = DescriptorMetadataSource.Function(
declaration.descriptor.findFunction(ParcelableSyntheticComponent.ComponentKind.DESCRIBE_CONTENTS)!!
)
}
@@ -178,7 +178,7 @@ class ParcelableIrTransformer(private val context: IrPluginContext, private val
}
}
metadata = MetadataSource.Function(
metadata = DescriptorMetadataSource.Function(
declaration.descriptor.findFunction(ParcelableSyntheticComponent.ComponentKind.WRITE_TO_PARCEL)!!
)
}