MCPcopy Create free account
hub / github.com/pybind/pybind11 / operator new

Method operator new

tests/test_class.cpp:346–349  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

344 struct AliasedHasOpNewDelSize {
345 std::uint64_t i;
346 static void *operator new(size_t s) {
347 py::print("C new", s);
348 return ::operator new(s);
349 }
350 static void *operator new(size_t s, void *ptr) {
351 py::print("C placement-new", s);
352 return ptr;

Callers

nothing calls this directly

Calls 1

printFunction · 0.85

Tested by

no test coverage detected