https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116070

            Bug ID: 116070
           Summary: broken headers for compile with flags -std=gnu++14
                    -fconcepts
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libstdc++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: alexey.lapshin at espressif dot com
  Target Milestone: ---

To reproduce run any of GCC:
13.3.0+
14.1.0+
15.0+

Reproducer:

#include <memory>
#include <vector>

int main() { return 0;}



Errors:

In file included from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/move.h:37,
                 from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/new_allocator.h:36,
                 from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/x86_64-linux-gnu/bits/c++allocator.h:33,
                 from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/allocator.h:46,
                 from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/memory:65,
                 from <source>:1:
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/type_traits:2575:12:
error: template parameters not deducible in partial specialization:
 2575 |     struct __result_of_memobj<_Res _Class::*, _Arg>
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/type_traits:2575:12: note:
        '_Class'
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/type_traits:2590:12:
error: template parameters not deducible in partial specialization:
 2590 |     struct __result_of_memfun<_Res _Class::*, _Arg, _Args...>
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/type_traits:2590:12: note:
        '_Class'
In file included from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/shared_ptr_base.h:57,
                 from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/shared_ptr.h:53,
                 from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/memory:80:
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/refwrap.h:176:12:
error: template parameters not deducible in partial specialization:
  176 |     struct _Weak_result_type_memfun<_Func _Class::*, false>
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/refwrap.h:176:12:
note:         '_Class'
In file included from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/exception:166,
                 from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/ext/concurrence.h:34,
                 from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/shared_ptr_base.h:62:
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/exception_ptr.h:205:20:
error: declaration of '~ std::__exception_ptr::exception_ptr' as non-member
  205 |     exception_ptr::~exception_ptr() _GLIBCXX_USE_NOEXCEPT
      |                    ^~~~~~~~~~~~~~
In file included from
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/vector:67,
                 from <source>:2:
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/stl_bvector.h:597:18:
error: 'is_default_constructible_v' was not declared in this scope; did you
mean 'is_default_constructible'?
  597 |         requires is_default_constructible_v<_Bit_alloc_type>
      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~
      |                  is_default_constructible
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/stl_bvector.h:597:9:
error: expression must be enclosed in parentheses
  597 |         requires is_default_constructible_v<_Bit_alloc_type>
      |         ^~~~~~~~
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/stl_bvector.h:597:9:
error: expected ';' at end of member declaration
  597 |         requires is_default_constructible_v<_Bit_alloc_type>
      |         ^~~~~~~~
      |                 ;
/opt/compiler-explorer/gcc-14.1.0/include/c++/14.1.0/bits/stl_bvector.h:597:18:
error: 'is_default_constructible_v' does not name a type; did you mean
'is_default_constructible'?
  597 |         requires is_default_constructible_v<_Bit_alloc_type>
      |                  ^~~~~~~~~~~~~~~~~~~~~~~~~~
      |                  is_default_constructible
Compiler returned: 1

Reply via email to