def cookie.slashes

emerging-ezhttp@0.21.0.0 · src/cookie.bend:328

import emerging-ezhttp@0.21.0.0/src/cookie.bend as Cookie
import Base

328# how many slashes a path holds
329def cookie.slashes(p: String) -> Nat:
330  match p:
331    case SNil{}:
332      0n
333    case SCon{h, t}:
334      cookie.slashes.ch(Char.is_eq(h, '/'), _u => cookie.slashes(t))

Uses (5)

Used by (1)