[gcc r17-4945] libstdc++: add std:: to pmr alias templates

Jason Merrill jason@gcc.gnu.org
Wed Oct 7 04:34:12 GMT 2026


https://gcc.gnu.org/g:f73ad52c42f610dea1027342134d7ba624a291f9

commit r17-4945-gf73ad52c42f610dea1027342134d7ba624a291f9
Author: Jason Merrill <jason@redhat.com>
Date:   Thu Oct 1 23:42:18 2026 +0200

    libstdc++: add std:: to pmr alias templates
    
    When #including this header after import std per P1811, the alias template
    is already in scope, so we can't use the unqualified name to refer to the
    template in std.  So use a qualified name.
    
    libstdc++-v3/ChangeLog:
    
            * include/bits/indirect.h (pmr::indirect): Add std:: qualification.
            (pmr::polymorphic): Likewise.

Diff:
---
 libstdc++-v3/include/bits/indirect.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libstdc++-v3/include/bits/indirect.h b/libstdc++-v3/include/bits/indirect.h
index cb6e9535a8e1..9aff4794f0bf 100644
--- a/libstdc++-v3/include/bits/indirect.h
+++ b/libstdc++-v3/include/bits/indirect.h
@@ -62,7 +62,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
   namespace pmr
   {
     template<typename _Tp>
-      using indirect = indirect<_Tp, polymorphic_allocator<_Tp>>;
+      using indirect = std::indirect<_Tp, polymorphic_allocator<_Tp>>;
   }
 #endif
 
@@ -462,7 +462,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
   namespace pmr
   {
     template<typename _Tp>
-      using polymorphic = polymorphic<_Tp, polymorphic_allocator<_Tp>>;
+      using polymorphic = std::polymorphic<_Tp, polymorphic_allocator<_Tp>>;
   }
 
   // [polymorphic], class template polymorphic


More information about the Libstdc++-cvs mailing list