Teensy 4.1 core updated for C++20
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

new.h 674B

1234567891011121314151617181920212223242526
  1. /* Header to define new/delete operators as they aren't provided by avr-gcc by default
  2. Taken from http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=59453
  3. */
  4. #ifndef NEW_H
  5. #define NEW_H
  6. #ifdef __cplusplus
  7. #include <stdlib.h>
  8. void * operator new(size_t size);
  9. void * operator new[](size_t size);
  10. void operator delete(void * ptr);
  11. void operator delete[](void * ptr);
  12. __extension__ typedef int __guard __attribute__((mode (__DI__)));
  13. extern "C" int __cxa_guard_acquire(__guard *);
  14. extern "C" void __cxa_guard_release (__guard *);
  15. extern "C" void __cxa_guard_abort (__guard *);
  16. extern "C" void __cxa_pure_virtual(void);
  17. #endif // __cplusplus
  18. #endif