mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-26 00:26:05 +00:00

This effort has quite a history: - This was first attempted in 2022 via bed3240bf7d1, which broke std::shared_ptr<T const> and caused the change to be reverted in 9138666f5464. - We then re-attempted landing the change in 276ca87382b8 after fixing std::shared_ptr, but reports were made that this broke code en masse within Google. This led to the patch being reverted again in a54d028895c9 with the goal to land this again with a migration path for vendors. This patch re-lands the removal while providing a migration path for vendors by providing the `_LIBCPP_ENABLE_REMOVED_ALLOCATOR_CONST` macro. This macro will be honored for the LLVM 19 release and will be removed after that, at which point allocator<const T> will be removed unconditionally. Fixes #73665