News for hackers. Stuff that matters.
Re:CppCon 2022 by chubot on Saturday September 17, 2022 @12:24PM (#32878752)
It is a tiny function that is basically equivalent to that macro, but using variadic templates:

    template <typename T, typename... Args>
    T* Alloc(Args&&... args) {
      assert(gHeap.is_initialized_);
      void* place = gHeap.Allocate(sizeof(T));
      assert(place != nullptr);
      // placement new
      return new (place) T(std::forward<Args>(args)...);
    }
https://github.com/oilshell/oil/blob/master/mycpp/gc_heap.h#...

So there is nothing to really break up

Re:CppCon 2022 by cma on Saturday September 17, 2022 @01:12PM (#32879171)
Make it forced-inline and it should be more similar to the macro.
Re:CppCon 2022 by jcelerier on Saturday September 17, 2022 @06:25PM (#32882210)
It also needs to be marked as hidden or internal visibility (or be made static) otherwise an instantiation will likely still be present in the binary