Open aqjune opened 5 years ago
https://isocpp.org/wiki/faq/freestore-mgmt#mixing-malloc-and-delete says it is not allowed:
there is no guarantee that the mechanism used by new and delete to acquire and release raw memory is compatible with malloc() and free(). If mixing styles works on your system, you were simply “lucky” – for now.
Another link that might be helpful: https://reviews.llvm.org/D95095 It looks like a new operator has more freedom to do 'things'.
It is not clear whether
and
is okay in LLVM IR. This should be clarified.