def any.go

bend-lint-api@0.2.0.0 · shared/lists.bend:43

import bend-lint-api@0.2.0.0/shared/lists.bend as Lists
import Base

43def any.go(~A: Data, ~f: A -> Bool, xs: List<&2, A>, found: Bool) -> Bool:
44  match xs found:
45    case _ True{}:
46      True{}
47    case Nil{} False{}:
48      False{}
49    case Con{h, t} False{}:
50      any.go(~A, ~f, t, f(h))

Uses (2)

Used by (1)