std::pmr::m...::deallocate(3)
π NAME π
okay so bestie, this page is all about std::pmr::memory_resource::deallocate β yes, the whole entire name β and it's from the C++ Standard Libary (that's their spelling, not mine π). it's giving "memory cleanup but make it polymorphic" β¨
πΈ Synopsis πΈ
void deallocate( void* p,
std::size_t bytes,
(since C++17)
std::size_t alignment = alignof(std::max_align_t) );
so like, deallocate deallocates the storage pointed to by p π«Ά. but bestie, listen: p shall have been returned by a prior call to allocate(bytes, alignment) on a memory_resource that compares equal to *this, and the storage it points to shall not yet have been deallocated. no cap, those are the rules π
it's equivalent to do_deallocate(p, bytes, alignment); β literally that. that's the whole vibe. periodt π
π Exceptions π
Throws nothing. zero drama, zero mess, she's unbothered π
π See also π
do_deallocateβ deallocates memory. it's a[virtual]virtual private member function, iykyk π§
big kiss to http://cppreference.com and version 2024.06.10 for this std::pmr::m...::deallocate(3) moment β mwah ππ
π¦ where this page comes from
- nixpkgs unstable: stdman 2024.07.05
- opensuse-leap 16.0: stdman 2024.07.05-bp160.1.9 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms