Law.gaps: def of bolt@1.27.0.0 Import: import bolt@1.27.0.0/src/rules/laws/law.bend as Law Lines 126-142 of bolt@1.27.0.0/src/rules/laws/law.bend: https://jend.leeeet.dev/read.txt?path=bolt@1.27.0.0/src/rules/laws/law.bend&start_line=126&end_line=142 import Base import bolt@1.27.0.0/src/lazy/lazy.bend as Lazy import bolt@1.27.0.0/src/finding.bend as F import bolt@1.27.0.0/src/syntax/outline.bend as Outline import bolt@1.27.0.0/src/rules/digest.bend as Digest import bolt@1.27.0.0/src/rules/imports.bend as Imports # a def, or a type, that no law reaches def gaps(ts: List<&2, Digest.Top>, +cl: List<&2, String>, +pp: String, +path: String) -> List<&2, F.Finding>: match ts: case Nil{}: Nil{} case Con{Digest.Top{Outline.IDef{}, +name, +line, cs, calls}, rest}: +more = gaps(rest, cl, pp, path) Bool.pick(List<&2, F.Finding>, Lazy.or_else(String.contains(name, "."), _u => Imports.has(cl, key(pp, name))), more, F.Finding{path, line, 0, 0, "coverage", "No quantified law reaches def " ++ name ++ "."} <> more) case Con{Digest.Top{Outline.IType{}, +name, +line, cs, calls}, rest}: +more = gaps(rest, cl, pp, path) Bool.pick(List<&2, F.Finding>, Lazy.or_else(Imports.has(cl, key(pp, name)), _u => any_item(cs, cl, pp)), more, F.Finding{path, line, 0, 0, "coverage", "No quantified law reaches type " ++ name ++ " or any of its constructors."} <> more) case Con{other, rest}: gaps(rest, cl, pp, path) Uses (12): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.pick https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.append https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.contains https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/finding.bend&name=Finding https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/lazy/lazy.bend&name=or_else https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/rules/digest.bend&name=Top https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/rules/imports.bend&name=has https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/rules/laws/law.bend&name=any_item https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/rules/laws/law.bend&name=key https://jend.leeeet.dev/definition.txt?path=bolt@1.27.0.0/src/syntax/outline.bend&name=ItemKind