def cookie.longer

bend-kit-http@0.38.2.0 · http.bend:2414

import bend-kit-http@0.38.2.0/http.bend as Http
import Base

2414# The sort order of §5.8.3: longer paths first; the stable sort keeps creation order among equals.
2415def cookie.longer(a: Cookie, b: Cookie) -> Bool:
2416  Cookie{n1, v1, d1, h1, p1, s1, o1, ss1, e1} = a
2417  Cookie{n2, v2, d2, h2, p2, s2, o2, ss2, e2} = b
2418  Bool.not(Nat.is_lt(String.length(p1), String.length(p2)))

Uses (5)

Used by (1)