def seen.has
import ezx@1.11.0.0/src/pkg/pkg.bend as Pkgimport Base
496# whether a name is already among the ones the walk has reached. Base's
497# `List.contains` applies an erased equality, which falls outside the
498# termination check; this scan is structural.
499def seen.has(xs: List<&2, String>, +want: String) -> Bool:
500 match xs:
501 case []:
502 False{}
503 case +h <> t:
504 seen.has.step(String.eq(h, want), _u => seen.has(t, want))