General Purpose library for Freestanding C++ and POSIX systems
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
255 B

  1. #pragma once
  2. #include <stddef.h>
  3. namespace gp {
  4. struct dummy_allocator{
  5. void* allocate(size_t)
  6. {
  7. return nullptr;
  8. }
  9. bool deallocate(void*)
  10. {
  11. return false;
  12. }
  13. constexpr bool try_reallocate(void*, size_t) {
  14. return false;
  15. }
  16. };
  17. }