Dns.tries: def of bend-kit-dns@0.7.0.0 Import: import bend-kit-dns@0.7.0.0/dns.bend as Dns Lines 494-507 of bend-kit-dns@0.7.0.0/dns.bend: https://jend.leeeet.dev/read.txt?path=bend-kit-dns@0.7.0.0/dns.bend&start_line=494&end_line=507 import Base # fuel: attempts left (resolv.conf's default is 2). def tries(fuel: Nat, +ns: String, +id: U32, +name: String, st: Socket & Try) -> IO(Maybe<&2, String>): match fuel: case 0n: tries.end(st) case 1n+f: (s, t) = st match t: case Got{ip}: try.close(s, ip) case Again{}: do IO>: next : Socket & Try <- try.once(s, ns, id, name) tries(f, ns, id, name, next) Uses (13): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.bind https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Socket https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=bend-kit-dns@0.7.0.0/dns.bend&name=Try https://jend.leeeet.dev/definition.txt?path=bend-kit-dns@0.7.0.0/dns.bend&name=tries.end https://jend.leeeet.dev/definition.txt?path=bend-kit-dns@0.7.0.0/dns.bend&name=try.close https://jend.leeeet.dev/definition.txt?path=bend-kit-dns@0.7.0.0/dns.bend&name=try.once