def flags.ok

bend-kit-dns@0.7.0.0 · dns.bend:296

import bend-kit-dns@0.7.0.0/dns.bend as Dns
import Base

296# §4.1.1: QR set, opcode QUERY, not truncated, RCODE 0.
297def flags.ok(+f: U32) -> Bool:
298  Bool.and(Bool.and(U32.is_eq(U32.and(f, 32768), 32768), U32.is_eq(U32.and(f, 30720), 0)), Bool.and(U32.is_eq(U32.and(f, 512), 0), U32.is_eq(U32.and(f, 15), 0)))

Uses (5)

Used by (1)