[libcxx-commits] [PATCH] D63744: In the libc++ unstable ABI, use [[no_unique_address]] instead of __compressed_pair when available.
Eric Fiselier via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Jun 25 16:04:45 PDT 2019
EricWF added a comment.
Thanks for working on this! `__compressed_pair` is a menace which causes serious template and code bloat.
And the code without it is much clearer and cleaner.
But...
I'm concerned by the number and size of the conditional compilation blocks this introduces.
In my time on libc++ conditional compilation blocks have been a frequent source of bugs; and I've been working to remove as many as I can.
I haven't figured out a cleaner way to implement this.
Does anyone have ideas on how we might eat our cake and have it too?
================
Comment at: libcxx/include/__hash_table:1009
__compressed_pair<float, key_equal> __p3_;
+ #define __first_node_ __p1_.first()
+ #define __size_ __p2_.first()
----------------
I really don't like this `#define` approach. Perhaps we could create accessor functions instead?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D63744/new/
https://reviews.llvm.org/D63744
More information about the libcxx-commits
mailing list