BendLintRules.Spans.has: def of bend-lint-rules@0.2.0.0 Import: import bend-lint-rules@0.2.0.0/lib/text/main.bend as BendLintRules Lines 156-166 of bend-lint-rules@0.2.0.0/lib/text/main.bend: https://jend.leeeet.dev/read.txt?path=bend-lint-rules@0.2.0.0/lib/text/main.bend&start_line=156&end_line=166 import Base # Whether `t` holds the span from `b` to `e`; `side` is how it compares with the root's. def Spans.has(t: Spans, +b: U32, +e: U32, side: Cmp) -> Bool: match t side: case SLeaf{} _: False{} case SNode{h, l, x, y, r} EQ{}: True{} case SNode{h, +l, x, y, r} LT{}: Spans.has(l, b, e, Spans.cmp(l, b, e)) case SNode{h, l, x, y, +r} GT{}: Spans.has(r, b, e, Spans.cmp(r, b, e)) Uses (5): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Cmp https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=bend-lint-rules@0.2.0.0/lib/text/main.bend&name=Spans https://jend.leeeet.dev/definition.txt?path=bend-lint-rules@0.2.0.0/lib/text/main.bend&name=Spans.cmp