Skip to content

Commit

Permalink
more test fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
dietmarkuehl committed Jan 23, 2025
1 parent 292962b commit 0ddebf4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ compile:
cmake --workflow --preset=appleclang-debug

format:
git clang-format
git clang-format

test: compile
cd $(BUILDDIR); ctest
Expand Down
7 changes: 2 additions & 5 deletions tests/beman/lazy/allocator_support.test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,8 @@ struct test_resource : std::pmr::memory_resource {
this->outstanding += size;
return ::operator new(size);
}
virtual void do_deallocate(void* ptr, std::size_t size, std::size_t align) override {
if constexpr (requires{ ::operator delete(ptr, size); })
::operator delete(ptr, size);
else
::operator delete(ptr);
virtual void do_deallocate(void* ptr, std::size_t size, std::size_t) override {
::operator delete(ptr);

this->outstanding -= size;
}
Expand Down

0 comments on commit 0ddebf4

Please sign in to comment.