__GNU_CXX::MALLOC_ALLOCATOR(3)
π NAME π
__gnu_cxx::malloc_allocator< _Tp > β an allocator that uses malloc. that's it, that's the whole vibe bestie π«Ά
β¨ SYNOPSIS β¨
okay so first things first, you gotta pull her in:
#include <malloc_allocator.h>
πΈ Public Types πΈ
the little typedef besties, no cap:
typedef std::ptrdiff_t difference_typetypedef std::true_type propagate_on_container_move_assignmenttypedef std::size_t size_typetypedef _Tp value_type
π Public Member Functions π
the actual moves she makes:
constexpr malloc_allocator (const malloc_allocator &) noexcepttemplate<typename _Tp1> constexpr malloc_allocator (const malloc_allocator< _Tp1 > &) noexcept_Tp * allocate (size_type __n, const void *=0)void deallocate (_Tp *__p, size_type)
π¦ Friends π¦
she keeps her circle small, iconic behavior:
template<typename _Up> constexpr bool operator== (const malloc_allocator &, const malloc_allocator< _Up > &) noexcept
π Detailed Description π
template<typename _Tp>
class __gnu_cxx::malloc_allocator< _Tp >
"An allocator that uses malloc."
bestie this is precisely the allocator defined in the C++ Standard. like, she's not doing anything extra, she's not doing anything weird, she is the blueprint. main character energy fr fr. π
the way that she works:
- all allocation calls
mallocπ - all deallocation calls
freeβ
that's the whole personality. she mallocs, she frees. simple. elegant. ate. π₯
π Author π
Generated automatically by Doxygen for libstdc++ from the source code. not a human, just a robot doing her little thing π€β¨
okay that's the whole page bestie, mwah π this one came from libstdc++, and the page title is __gnu_cxx:...tor< _Tp >(3) β the (3) means she's a library function, iykyk. go forth and malloc responsibly π«ΆπΈ
π¦ where this page comes from
- arch rolling: gcc 16.2.1+r23+gd564253eb6c8-1 Β· GPL-3.0-or-later WITH GCC-exception-3.1 AND GFDL-1.3-or-later
- fedora 44: libstdc++-docs 16.0.1-0.10.fc44 Β· GPL-3.0-or-later AND LGPL-3.0-or-later AND (GPL-3.0-or-later WITH GCC-exception-3.1) AND (GPL-3.0-or-later WITH Texinfo-exception) AND (LGPL-2.1-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GNU-compiler-exception) AND BSL-1.0 AND GFDL-1.3-or-later AND Linux-man-pages-copyleft-2-para AND SunPro AND BSD-1-Clause AND BSD-2-Clause AND BSD-2-Clause-Views AND BSD-3-Clause AND BSD-4-Clause AND BSD-Source-Code AND Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 WITH LLVM-Exception) AND ZPL-2.1 AND ISC AND LicenseRef-Fedora-Public-Domain AND HP-1986 AND curl AND Martin-Birgmeier AND HPND-Markus-Kuhn AND dtoa AND SMLNJ AND AMD-newlib AND OAR AND HPND-merchantability-variant AND HPND-Intel
- fedora 44: libstdc++-docs 16.2.1-2.fc44
- fedora 44: libstdc++-docs 16.2.1-3.fc44 Β· GPL-3.0-or-later AND LGPL-3.0-or-later AND (GPL-3.0-or-later WITH GCC-exception-3.1) AND (GPL-3.0-or-later WITH Texinfo-exception) AND (LGPL-2.1-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GNU-compiler-exception) AND BSL-1.0 AND GFDL-1.3-or-later AND Linux-man-pages-copyleft-2-para AND SunPro AND BSD-1-Clause AND BSD-2-Clause AND BSD-2-Clause-Views AND BSD-3-Clause AND BSD-4-Clause AND BSD-Source-Code AND Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 WITH LLVM-Exception) AND ZPL-2.1 AND ISC AND LicenseRef-Fedora-Public-Domain AND HP-1986 AND curl AND Martin-Birgmeier AND HPND-Markus-Kuhn AND dtoa AND SMLNJ AND AMD-newlib AND OAR AND HPND-merchantability-variant AND HPND-Intel
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms