def repeats.if

bend-lint-rules@0.2.0.0 · performance/loop_invariant_call.bend:202

import bend-lint-rules@0.2.0.0/performance/loop_invariant_call.bend as LoopInvariantCall
import Base
import bend-lint-api@0.2.0.0/linter/lint.bend as Lint

202# Whether the branch a node below `path` is in calls `target` again, if `found`.
203def repeats.if(found: Bool, path: List<&2, Lint.Above>, target: String) -> Bool:
204  match found:
205    case True{}:
206      repeats(branch(path, None{}), target)
207    case False{}:
208      False{}

Uses (7)

Used by (1)