15 *m_byte |= (1U << m_bit_offset);
17 *m_byte &= ~(1U << m_bit_offset);
24 return *
this = bool(other);
27 constexpr operator bool()
const {
return !!(*m_byte & (1U << m_bit_offset)); }
29 constexpr auto operator~() const ->
bool {
return !bool(*
this); }
32 *m_byte ^= (1U << m_bit_offset);
constexpr BitProxyReference(u8 *byte, u8 bit_offset)
Definition bit_proxy_reference.h:8
constexpr BitProxyReference(BitProxyReference const &)=default
constexpr auto operator=(BitProxyReference const &other) const -> BitProxyReference const &
Definition bit_proxy_reference.h:23
constexpr auto flip() const -> BitProxyReference const &
Definition bit_proxy_reference.h:31
constexpr auto operator~() const -> bool
Definition bit_proxy_reference.h:29
constexpr auto operator=(bool value) const -> BitProxyReference const &
Definition bit_proxy_reference.h:13
constexpr BitProxyReference(BitProxyReference &&)=default
Definition bit_proxy_reference.h:5
std::byte byte
Definition byte.h:64
__UINT8_TYPE__ u8
Definition integers.h:9