package altair // HasValidatorFlag returns true if the flag at position has set. func HasValidatorFlag(flag, flagPosition uint8) bool { return ((flag >> flagPosition) & 1) == 1 } // AddValidatorFlag adds new validator flag to existing one. func AddValidatorFlag(flag, flagPosition uint8) uint8 { return flag | (1 << flagPosition) }