| 344 | public: |
| 345 | explicit NoPlacementNew(int i) : i(i) {} |
| 346 | static void *operator new(std::size_t s) { |
| 347 | auto *p = ::operator new(s); |
| 348 | py::print("operator new called, returning", reinterpret_cast<uintptr_t>(p)); |
| 349 | return p; |
| 350 | } |
| 351 | static void operator delete(void *p) { |
| 352 | py::print("operator delete called on", reinterpret_cast<uintptr_t>(p)); |
| 353 | ::operator delete(p); |