Dunolinter.LinterSourcetype t = | Unhandled| T : {eval : path:Fpath_base.Relative_path.t ->
predicate:Dunolint.Predicate.t ->
Dunolint.Trilang.t;enforce : path:Fpath_base.Relative_path.t ->
condition:Dunolint.Predicate.t Dunolint.Std.Blang.t ->
Base.unit;} -> tval enforce :
(module Handler.Predicate with type t = 'predicate) ->
eval:('t -> predicate:'predicate -> Dunolint.Trilang.t) ->
enforce:('t -> 'predicate Predicate.t -> Enforce_result.t) ->
't ->
condition:'predicate Dunolint.Std.Blang.t ->
Base.unitA helper function that can be useful to implement the enforce function required by the Linter.S interface.
Returns the list of elements from the input condition that are directly reachable as elements to be enforced, without going through dynamic conditions or SAT logic. In practice, that is Base, and elements under And _ recursively.
A helper that applies some usually helpful heuristic when proposing a new name based on the `is_prefix predicate. Assumed to be called when the given prefix is not already a prefix of the input, otherwise the output is unspecified.