Using the C++ Math Library | ![]() ![]() |
Memory Management
Overloading the operators new
and delete
provides the necessary hooks for user-defined memory management. The MATLAB C++ Math Library has its own memory management scheme (See Memory Management in Chapter 7 for details).
If this scheme is inappropriate for your application, you can modify it. However, you should not do so by overloading new
and delete
, because the mwArray
class already contains overloaded versions of these operators:
void *operator new(size_t size)
void operator delete(void *ptr, size_t size)
![]() | User-Defined Conversions | Operators | ![]() |