def tzif.trans
import bend-kit-time@0.3.0.0/time.bend as Timeimport Base
645# ts holds the transition times and ks their type indexes.
646def tzif.trans(n: Nat, +t8: Bool, +ts: String, +ks: String) -> List<&2, Trans>:
647 match n:
648 case 0n:
649 Nil{}
650 case 1n+k:
651 Con{Trans{tzif.time(t8, ts), u8(ks, 0n)},
652 tzif.trans(k, t8, String.drop(ts, tzif.size(t8)), String.drop(ks, 1n))}