def show.load
bend-osdev-apparmor@0.1.0.0 · check.bend:30
import bend-osdev-apparmor@0.1.0.0/check.bend as Check
import Base
import bend-osdev-apparmor@0.1.0.0/error.bend as E
import bend-osdev-apparmor@0.1.0.0/profile.bend as PR
30def show.load(r: Result<&2, &2, E.AaError, PR.AaPolicy>) -> String:
31 match r:
32 case Fail{+e}:
33 "error " ++ E.AaError.name(e) ++ " at line " ++ U32.show(E.AaError.line(e))
34 case Done{p}:
35 "ok, " ++ Nat.show(List.length(&2, PR.AaProfile, PR.AaPolicy.profiles(p))) ++ " profiles"