[Commonizer] Explicitly check if annotation constants are allowed
This commit is contained in:
+2
-1
@@ -62,7 +62,8 @@ class CirPropertyImpl(original: PropertyDescriptor) : CirFunctionOrPropertyImpl<
|
|||||||
compileTimeInitializer?.let { compileTimeInitializer ->
|
compileTimeInitializer?.let { compileTimeInitializer ->
|
||||||
checkConstantSupportedInCommonization(
|
checkConstantSupportedInCommonization(
|
||||||
constantValue = compileTimeInitializer,
|
constantValue = compileTimeInitializer,
|
||||||
owner = original
|
owner = original,
|
||||||
|
allowAnnotationValues = false
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -12,7 +12,7 @@ internal fun checkConstantSupportedInCommonization(
|
|||||||
constantValue: ConstantValue<*>,
|
constantValue: ConstantValue<*>,
|
||||||
constantName: Name? = null,
|
constantName: Name? = null,
|
||||||
owner: Any,
|
owner: Any,
|
||||||
allowAnnotationValues: Boolean = false,
|
allowAnnotationValues: Boolean,
|
||||||
onError: (String) -> Nothing = ::error
|
onError: (String) -> Nothing = ::error
|
||||||
) {
|
) {
|
||||||
checkConstantSupportedInCommonization(
|
checkConstantSupportedInCommonization(
|
||||||
|
|||||||
Reference in New Issue
Block a user