Module Nullsafe.OverAnnotatedRule

type violation
val compare_violation : violation -> violation -> int
val check : what:Nullability.t -> by_rhs_upper_bound:Nullability.t -> (unit, violation) IStdlib.IStd.result

Checks if the declared type for `what` can be narrowed, based on the information about all assignments `what = rhs_i`. If an upper bound of `rhs_i` over ALL assignents `what = rhs_i` that exist in the program is a _strict_ subtype of lhs, `lhs`'s type can be narrowed to be that upper bound.

type violation_type =
| FieldOverAnnoted of IR.Fieldname.t
| ReturnOverAnnotated of IR.Procname.Java.t

Return value of a method can be made non-nullable

val compare_violation_type : violation_type -> violation_type -> int
val violation_description : violation -> violation_type -> string