def named
import bolt@1.27.0.0/src/walk/disk.bend as Diskimport Base
24# the named lines: the text ends in a newline, so the last line is empty
25def named(ls: List<&2, String>) -> List<&2, String>:
26 match ls:
27 case Nil{}:
28 Nil{}
29 case Con{+l, t}:
30 +more = named(t)
31 Bool.pick(List<&2, String>, String.is_empty(l), more, l <> more)