[NI] Minor, use singleton instead of creating anonymous object
This commit is contained in:
+1
-2
@@ -26,8 +26,7 @@ object NewCommonSuperTypeCalculator {
|
|||||||
|
|
||||||
// TODO: Bridge for old calls
|
// TODO: Bridge for old calls
|
||||||
fun commonSuperType(types: List<UnwrappedType>): UnwrappedType {
|
fun commonSuperType(types: List<UnwrappedType>): UnwrappedType {
|
||||||
val ctx = object : ClassicTypeSystemContext {}
|
return SimpleClassicTypeSystemContext.commonSuperType(types) as UnwrappedType
|
||||||
return ctx.commonSuperType(types) as UnwrappedType
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun TypeSystemCommonSuperTypesContext.commonSuperType(types: List<KotlinTypeMarker>): KotlinTypeMarker {
|
fun TypeSystemCommonSuperTypesContext.commonSuperType(types: List<KotlinTypeMarker>): KotlinTypeMarker {
|
||||||
|
|||||||
Reference in New Issue
Block a user