func SetBit(bitfield []byte, id uint32) ([]byte, error) {
	if uint32(len(bitfield)*8) <= id {
		return nil, fmt.Errorf("bitfield is too short")
	}

	bitfield[id/8] = bitfield[id/8] | (1 << (id % 8))

	return bitfield, nil
}
// SetBit sets a bit in a bitfield.
SetBit sets a bit in a bitfield.
// SetBit sets a bit in a bitfield .
func SetBit(bitfield []byte, id uint32) ([]byte, error) {
	if uint32(len(bitfield)*8) <= id {
		return nil, fmt.Errorf("bitfield is too short")
	}
	bitfield[id/8] = bitfield[id/8] | (1 << (id % 8))
	return bitfield, nil
}
func SetBit ( bitfield [ ] byte , id uint32 ) ( [ ] byte , error ) { if uint32 ( len ( bitfield ) * 8 ) <= id { return nil , fmt . Errorf ( " " ) } bitfield [ id / 8 ] = bitfield [ id / 8 ] | ( 1 << ( id % 8 ) ) return bitfield , nil }
SetBit sets a bit in a bitfield.
SetBit sets a bit in a bitfield .