Include file:

#include "mcrl2/utilities/tagged_pointer.h
class mcrl2::utilities::tagged_pointer

A pointer storage object that uses a least significant bit as a mark. Can be used by objects that are 8 bytes aligned in memory.

Private attributes

T *mcrl2::utilities::tagged_pointer::m_pointer

Public member functions

bool defined() const
T *get()
const T *get() const
bool operator!=(const tagged_pointer &other) const
bool operator!=(std::nullptr_t) const
T &operator*()
const T &operator*() const
T *operator->()
const T *operator->() const
bool operator<(const tagged_pointer &other) const noexcept
bool operator<=(const tagged_pointer &other) const noexcept
void operator=(std::nullptr_t)
bool operator==(const tagged_pointer &other) const
bool operator==(std::nullptr_t) const
bool operator>(const tagged_pointer &other) const noexcept
bool operator>=(const tagged_pointer &other) const noexcept
void tag() const

Apply a tag to the pointer that can be checked with tagged().

bool tagged() const

Returns: True iff this pointer has been tagged,

tagged_pointer(T *p)
void untag() const

Remove the tag.