martinus / unordered_dense

A fast & densely stored hashmap and hashset based on robin-hood backward shift deletion
MIT License
898 stars 72 forks source link

add libc++ compatibility by checking for <experimental/memory_resource> #57

Closed justusranvier closed 1 year ago

justusranvier commented 1 year ago

Until LLVM 16 is released, and until Android and Apple platforms incorporate the forthcoming std::pmr support in their forks of libc++, this workaround is needed to use pmr containers on those platforms.

justusranvier commented 1 year ago

Those CI check results are unfortunate. I can easily fix the clang-format issue but making the pmr unit test pass on macos would involve some pretty intrusive changes.

In my project I have to jump through several hoops to get pmr working on macos. It basically involves creating an alias for every pmr type and use the preprocessor to make sure they resolve to the correct namespace.

martinus commented 1 year ago

I'm fine with you just #ifdef-ing the test out for macos, e.g. add something to the condition of #if ANKERL_UNORDERED_DENSE_PMR in pmr.cpp. Not sure though how to detect macos

martinus commented 1 year ago

Thanks for your contribution!

martinus commented 1 year ago

I created a new release v3.0.2 with your changes