#include "Stroika/Foundation/StroikaPreComp.h"
#include <memory>
#include "Stroika/Foundation/Common/Common.h"
#include "Bits.inl"
Go to the source code of this file.
Namespaces | |
namespace | Stroika::Foundation |
Functions | |
template<integral INT_TYPE = unsigned int> | |
constexpr INT_TYPE | Stroika::Foundation::Memory::Bit (unsigned int bitNumber) |
template<integral INT_TYPE> | |
constexpr INT_TYPE | Stroika::Foundation::Memory::BitSubstring (INT_TYPE bitField, unsigned int startOffset, unsigned int endOffset) |
|
constexpr |
|
constexpr |
Capture the bits from 'bitField' - starting at bit 'startOffset' (zero-based), extending to endOffset (also zero based - not inclusive). The number of bits captured is endOffset-startOffset, so:
the result is zero-filled with bits, so if zero bits are captured, the return value will be zero.