General Purpose library for Freestanding C++ and POSIX systems
25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.

16 satır
297 B

  1. #pragma once
  2. #include "gp/allocator/buddy.hpp"
  3. #include "gp/allocator/dummy.hpp"
  4. struct static_mapper {
  5. static gp::array<char, 4096> store;
  6. static gp::buddy<> impl;
  7. void* allocate(size_t sz) {
  8. return impl.allocate(sz);
  9. }
  10. bool deallocate(void* ptr) {
  11. return impl.deallocate(ptr);
  12. }
  13. };