diff --git a/inc/core/MicroBitHeapAllocator.h b/inc/core/MicroBitHeapAllocator.h index 7b92936..0f0dfb5 100644 --- a/inc/core/MicroBitHeapAllocator.h +++ b/inc/core/MicroBitHeapAllocator.h @@ -136,7 +136,7 @@ inline void native_free(void *p) /** * Overrides the 'new' operator globally, and redirects calls to the micro:bit heap allocator. */ -inline void* operator new(size_t size) throw(std::bad_alloc) +inline void* operator new(size_t size) { return microbit_malloc(size); } @@ -144,7 +144,7 @@ inline void* operator new(size_t size) throw(std::bad_alloc) /** * Overrides the 'new' operator globally, and redirects calls to the micro:bit theap allocator. */ -inline void* operator new[](size_t size) throw(std::bad_alloc) +inline void* operator new[](size_t size) { return microbit_malloc(size); } @@ -152,7 +152,7 @@ inline void* operator new[](size_t size) throw(std::bad_alloc) /** * Overrides the 'delete' operator globally, and redirects calls to the micro:bit theap allocator. */ -inline void operator delete(void *ptr) throw() +inline void operator delete(void *ptr) { microbit_free(ptr); }