https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99735
Bug ID: 99735 Summary: [modules] in system headers: non-template type ‘rebind_alloc’ used as a template Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: alexander.lelyakin at googlemail dot com Target Milestone: --- /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header ccomplex /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header system_error /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header locale /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header unordered_map /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header numbers /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header cstddef /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header variant /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header complex /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header stack /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header sstream /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header mutex /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header charconv /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header filesystem ---- In file included from /usr/local/include/c++/11.0.1/filesystem:45: /usr/local/include/c++/11.0.1/bits/fs_path.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::filesystem::__cxx11::path::generic_string(const _Allocator&) const [with _CharT = char; _Traits = std::char_traits<char>; _Allocator = std::allocator<char>]’: /usr/local/include/c++/11.0.1/bits/fs_path.h:1165:33: required from here /usr/local/include/c++/11.0.1/bits/fs_path.h:1131:13: error: non-template type ‘rebind_alloc’ used as a template 1131 | using _Alloc2 = typename allocator_traits<_Allocator>::template | ^~~~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template 1133 | basic_string<value_type, char_traits<value_type>, _Alloc2> __str(__a); | ^~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template /usr/local/include/c++/11.0.1/bits/fs_path.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::filesystem::__cxx11::path::generic_string(const _Allocator&) const [with _CharT = wchar_t; _Traits = std::char_traits<wchar_t>; _Allocator = std::allocator<wchar_t>]’: /usr/local/include/c++/11.0.1/bits/fs_path.h:1170:36: required from here /usr/local/include/c++/11.0.1/bits/fs_path.h:1131:13: error: non-template type ‘rebind_alloc’ used as a template 1131 | using _Alloc2 = typename allocator_traits<_Allocator>::template | ^~~~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template 1133 | basic_string<value_type, char_traits<value_type>, _Alloc2> __str(__a); | ^~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template /usr/local/include/c++/11.0.1/bits/fs_path.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::filesystem::__cxx11::path::generic_string(const _Allocator&) const [with _CharT = char8_t; _Traits = std::char_traits<char8_t>; _Allocator = std::allocator<char8_t>]’: /usr/local/include/c++/11.0.1/bits/fs_path.h:1176:36: required from here /usr/local/include/c++/11.0.1/bits/fs_path.h:1131:13: error: non-template type ‘rebind_alloc’ used as a template 1131 | using _Alloc2 = typename allocator_traits<_Allocator>::template | ^~~~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template 1133 | basic_string<value_type, char_traits<value_type>, _Alloc2> __str(__a); | ^~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template /usr/local/include/c++/11.0.1/bits/fs_path.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::filesystem::__cxx11::path::generic_string(const _Allocator&) const [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; _Allocator = std::allocator<char16_t>]’: /usr/local/include/c++/11.0.1/bits/fs_path.h:1185:37: required from here /usr/local/include/c++/11.0.1/bits/fs_path.h:1131:13: error: non-template type ‘rebind_alloc’ used as a template 1131 | using _Alloc2 = typename allocator_traits<_Allocator>::template | ^~~~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template 1133 | basic_string<value_type, char_traits<value_type>, _Alloc2> __str(__a); | ^~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template /usr/local/include/c++/11.0.1/bits/fs_path.h: In instantiation of ‘std::__cxx11::basic_string<_CharT, _Traits, _Allocator> std::filesystem::__cxx11::path::generic_string(const _Allocator&) const [with _CharT = char32_t; _Traits = std::char_traits<char32_t>; _Allocator = std::allocator<char32_t>]’: /usr/local/include/c++/11.0.1/bits/fs_path.h:1189:37: required from here /usr/local/include/c++/11.0.1/bits/fs_path.h:1131:13: error: non-template type ‘rebind_alloc’ used as a template 1131 | using _Alloc2 = typename allocator_traits<_Allocator>::template | ^~~~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template 1133 | basic_string<value_type, char_traits<value_type>, _Alloc2> __str(__a); | ^~~~~ /usr/local/include/c++/11.0.1/bits/fs_path.h:1133:66: error: non-template type ‘rebind_alloc’ used as a template /usr/local/include/c++/11.0.1/filesystem: warning: not writing module ‘/usr/local/include/c++/11.0.1/filesystem’ due to errors ---- g++ (GCC) 11.0.1 20210323 (experimental) Copyright (C) 2021 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.