KT-11588 Type aliases
Proper abbreviated type for '<type-alias>?'
This commit is contained in:
@@ -91,7 +91,16 @@ public class PossiblyBareType {
|
|||||||
if (isBare()) {
|
if (isBare()) {
|
||||||
return isBareTypeNullable() ? this : bare(getBareTypeConstructor(), true);
|
return isBareTypeNullable() ? this : bare(getBareTypeConstructor(), true);
|
||||||
}
|
}
|
||||||
return type(TypeUtils.makeNullable(getActualType()));
|
|
||||||
|
KotlinType nullableActualType = TypeUtils.makeNullable(getActualType());
|
||||||
|
|
||||||
|
KotlinType abbreviatedType = TypeCapabilitiesKt.getAbbreviatedType(getActualType());
|
||||||
|
if (abbreviatedType == null) {
|
||||||
|
return type(nullableActualType);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return type(TypeCapabilitiesKt.withAbbreviatedType(nullableActualType, TypeUtils.makeNullable(abbreviatedType)));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@NotNull
|
@NotNull
|
||||||
|
|||||||
@@ -4,6 +4,6 @@ public typealias S = kotlin.String
|
|||||||
public typealias SS = S
|
public typealias SS = S
|
||||||
public typealias SSS = SS
|
public typealias SSS = SS
|
||||||
public val s1: SSS [= kotlin.String] = ""
|
public val s1: SSS [= kotlin.String] = ""
|
||||||
public val s2: SSS [= kotlin.String?] = null
|
public val s2: SSS? [= kotlin.String?] = null
|
||||||
public val s3: kotlin.collections.List<SSS [= kotlin.String]>? = null
|
public val s3: kotlin.collections.List<SSS [= kotlin.String]>? = null
|
||||||
public val s4: kotlin.collections.List<kotlin.collections.List<SSS [= kotlin.String]>?>? = null
|
public val s4: kotlin.collections.List<kotlin.collections.List<SSS [= kotlin.String]>?>? = null
|
||||||
|
|||||||
Reference in New Issue
Block a user