mirror of
https://github.com/mmueller41/mxtasking.git
synced 2026-01-21 12:42:57 +01:00
Removed c++20 syntax
This commit is contained in:
@@ -12,7 +12,7 @@ namespace mx::memory {
|
|||||||
template <class T, typename I> class tagged_ptr
|
template <class T, typename I> class tagged_ptr
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
constexpr tagged_ptr() noexcept
|
constexpr tagged_ptr() noexcept : _object_pointer(0U)
|
||||||
{
|
{
|
||||||
static_assert(sizeof(I) == 2U);
|
static_assert(sizeof(I) == 2U);
|
||||||
static_assert(sizeof(tagged_ptr) == 8U);
|
static_assert(sizeof(tagged_ptr) == 8U);
|
||||||
@@ -81,7 +81,7 @@ private:
|
|||||||
/**
|
/**
|
||||||
* Pointer to the instance of T, only 48bit are used.
|
* Pointer to the instance of T, only 48bit are used.
|
||||||
*/
|
*/
|
||||||
std::uintptr_t _object_pointer : 48 {0U};
|
std::uintptr_t _object_pointer : 48;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Information stored within this pointer, remaining 16bit are used.
|
* Information stored within this pointer, remaining 16bit are used.
|
||||||
|
|||||||
@@ -164,7 +164,7 @@ private:
|
|||||||
class information
|
class information
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
constexpr information() noexcept = default;
|
constexpr information() noexcept : _channel_id(0U), _synchronization_primitive(0U) { }
|
||||||
explicit information(const std::uint16_t channel_id,
|
explicit information(const std::uint16_t channel_id,
|
||||||
const synchronization::primitive synchronization_primitive) noexcept
|
const synchronization::primitive synchronization_primitive) noexcept
|
||||||
: _channel_id(channel_id), _synchronization_primitive(static_cast<std::uint16_t>(synchronization_primitive))
|
: _channel_id(channel_id), _synchronization_primitive(static_cast<std::uint16_t>(synchronization_primitive))
|
||||||
@@ -182,8 +182,8 @@ public:
|
|||||||
information &operator=(const information &other) = default;
|
information &operator=(const information &other) = default;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::uint16_t _channel_id : 12 {0U};
|
std::uint16_t _channel_id : 12;
|
||||||
std::uint16_t _synchronization_primitive : 4 {0U};
|
std::uint16_t _synchronization_primitive : 4;
|
||||||
} __attribute__((packed));
|
} __attribute__((packed));
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user