CanonImportPath.segments.step: def of bend-lint-rules@0.2.0.0 Import: import bend-lint-rules@0.2.0.0/layout/canon_import_path.bend as CanonImportPath Lines 10-21 of bend-lint-rules@0.2.0.0/layout/canon_import_path.bend: https://jend.leeeet.dev/read.txt?path=bend-lint-rules@0.2.0.0/layout/canon_import_path.bend&start_line=10&end_line=21 import Base # Paths # ===== def segments.step(p: String, acc: List<&2, String>) -> List<&2, String>: match p: case SNil{}: acc case SCon{'.', SNil{}}: acc case SCon{'.', SCon{'.', SNil{}}}: List.tail(&2, String, acc) case SCon{c, rest}: SCon{c, rest} <> acc Uses (8): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Char https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List.tail https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Word.Con https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Word.Nil