def Gf8Bits.is_zero

bend-osdev-gf@0.1.1.0 · gf.bend:111

import bend-osdev-gf@0.1.1.0/gf.bend as Gf
import Base

111# whether a is the zero element (its low 8 bits are all 0)
112def Gf8Bits.is_zero(a: Gf8Bits) -> Bool:
113  match a:
114    case Gf8Bits{b0, b1, b2, b3, b4, b5, b6, b7}:
115      Bool.not(Bool.or(b0, Bool.or(b1, Bool.or(b2, Bool.or(b3, Bool.or(b4, Bool.or(b5, Bool.or(b6, b7))))))))

Uses (4)

Used by (12)