[NI] Don't consider Any!-constraint from upper bounds as more specific
#KT-31624 Fixed
This commit is contained in:
+4
-6
@@ -101,12 +101,10 @@ class ConstraintInjector(val constraintIncorporator: ConstraintIncorporator, val
|
||||
return true // T <: T(?!)
|
||||
}
|
||||
|
||||
if (constraintType.isSimpleType()) {
|
||||
if (constraint.position.from is DeclaredUpperBoundConstraintPosition &&
|
||||
constraint.kind == UPPER && constraintType.isNullableAny()
|
||||
) {
|
||||
return true // T <: Any?
|
||||
}
|
||||
if (constraint.position.from is DeclaredUpperBoundConstraintPosition &&
|
||||
constraint.kind == UPPER && constraintType.isNullableAny()
|
||||
) {
|
||||
return true // T <: Any?
|
||||
}
|
||||
|
||||
return false
|
||||
|
||||
Reference in New Issue
Block a user