In C++11\'s language feature list there is:
Minimal support for garbage collection and reachability-based leak detection
(but
There is a proposal to remove this GC support from standard:
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2020/p2186r0.html
and there is an C++ GC(Boehm): https://www.hboehm.info/gc/