diff --git a/compiler/frontend/src/org/jetbrains/kotlin/resolve/calls/inference/ConstraintSystemStatus.kt b/compiler/frontend/src/org/jetbrains/kotlin/resolve/calls/inference/ConstraintSystemStatus.kt index 23066051148..9f635a3c8b4 100644 --- a/compiler/frontend/src/org/jetbrains/kotlin/resolve/calls/inference/ConstraintSystemStatus.kt +++ b/compiler/frontend/src/org/jetbrains/kotlin/resolve/calls/inference/ConstraintSystemStatus.kt @@ -20,73 +20,73 @@ import org.jetbrains.kotlin.resolve.calls.inference.constraintPosition.Constrain public interface ConstraintSystemStatus { /** - * Returns true if constraint system has a solution (has no contradiction and has enough information to infer each registered type variable). + * Returns `true` if constraint system has a solution (has no contradiction and has enough information to infer each registered type variable). */ public fun isSuccessful(): Boolean /** - * Return true if constraint system has no contradiction (it can be not successful because of the lack of information for a type variable). + * Return `true` if constraint system has no contradiction (it can be not successful because of the lack of information for a type variable). */ public fun hasContradiction(): Boolean /** - * Returns true if type constraints for some type variable are contradicting.

+ * Returns `true` if type constraints for some type variable are contradicting. * - * For example, for

fun <R> foo(r: R, t: java.util.List<R>) {}
in invocation foo(1, arrayList("s")) - * type variable R has two conflicting constraints:

- * - "R is a supertype of Int"

- * - "List<R> is a supertype of List<String>" which leads to "R is equal to String" + * For example, for `fun foo(r: R, t: java.util.List) {}` in invocation `foo(1, arrayList("s"))` + * type variable `R` has two conflicting constraints: + * - "R is a supertype of Int" + * - "List is a supertype of List" which leads to "R is equal to String" */ public fun hasConflictingConstraints(): Boolean /** - * Returns true if contradiction of type constraints comes from declared bounds for type parameters. + * Returns `true` if contradiction of type constraints comes from declared bounds for type parameters. * - * For example, for

fun <R: Any> foo(r: R) {}
in invocation foo(null) - * upper bounds Any for type parameter R is violated.

+ * For example, for `fun foo(r: R) {}` in invocation `foo(null)` + * upper bounds `Any` for type parameter `R` is violated. * * It's the special case of 'hasConflictingConstraints' case. */ public fun hasViolatedUpperBound(): Boolean /** - * Returns true if there is no information for some registered type variable. + * Returns `true` if there is no information for some registered type variable. * - * For example, for

fun <E> newList()
in invocation "val nl = newList()" - * there is no information to infer type variable E. + * For example, for `fun newList()` in invocation `val nl = newList()` + * there is no information to infer type variable `E`. */ public fun hasUnknownParameters(): Boolean /** - * Returns true if some constraint cannot be processed because of type constructor mismatch. + * Returns `true` if some constraint cannot be processed because of type constructor mismatch. * - * For example, for
fun <R> foo(t: List<R>) {}
in invocation foo(hashSet("s")) - * there is type constructor mismatch: "HashSet<String> cannot be a subtype of List<R>". + * For example, for `fun foo(t: List) {}` in invocation `foo(hashSetOf("s"))` + * there is type constructor mismatch: "HashSet cannot be a subtype of List". */ public fun hasParameterConstraintError(): Boolean /** - * Returns true if there is type constructor mismatch only in constraintPosition or + * Returns `true` if there is type constructor mismatch only in constraintPosition or * constraint system is successful without constraints from this position. */ public fun hasOnlyErrorsDerivedFrom(kind: ConstraintPositionKind): Boolean /** - * Returns true if there is an error in constraining types.

+ * Returns `true` if there is an error in constraining types. * Is used not to generate type inference error if there was one in argument types. */ public fun hasErrorInConstrainingTypes(): Boolean /** - * Returns true if a user type contains the type projection that cannot be captured. + * Returns `true` if a user type contains the type projection that cannot be captured. * - * For example, for

fun <T> foo(t: Array<Array<T>>) {}
- * in invocation foo(array) where array has type Array<Array<out Int>>. + * For example, for `fun foo(t: Array>) {}` + * in invocation `foo(array)` where `array` has type `Array>`. */ public fun hasCannotCaptureTypesError(): Boolean /** - * Returns true if there's an error in constraint system incorporation. + * Returns `true` if there's an error in constraint system incorporation. */ public fun hasTypeInferenceIncorporationError(): Boolean