27 :
public std::pmr::memory_resource
30 constexpr
static size_t MAGIC = 0xdeadbeefcafefeed;
32 virtual void* do_allocate (
size_t bytes, std::size_t )
override
34 size_t*
p =
reinterpret_cast<size_t*
>(
malloc (bytes + 2*
sizeof(
size_t)));
40 virtual void do_deallocate (
void*
p, [[maybe_unused]] std::size_t bytes, std::size_t )
override
42 size_t* pp =
reinterpret_cast<size_t*
>(
p);
44 assert (pp[0] == bytes);
45 assert (pp[1] == MAGIC);
49 virtual bool do_is_equal (
const std::pmr::memory_resource&
other)
const noexcept
override
51 return dynamic_cast<const TestMemResource*
> (&
other) !=
nullptr;
67 :
xAOD::AuxContainerBase(&memRes)
73 :
xAOD::AuxContainerBase(),