https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87020
Bug ID: 87020 Summary: comparison operator isn't called for stateless allocator without is_always_equal for C++11/14 Product: gcc Version: 8.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: roland at rschulz dot eu Target Milestone: --- For an empty allocator the comparison operators aren't used, unless is_always_equal=std::false_type is present. This is the correct behavior with C++17 but for C++11/14 is_always_equal shouldn't have any effect. This is low impact because any well defined and state-less allocator should always be equal. But it isn't strictly compliant. This is present since GCC 6. Reproducer: https://godbolt.org/z/-5IHwC