On 24/11/17 18:03 +0100, Stephan Bergmann wrote:
Otherwise, at least recent Clang trunk with -std=gnu++17 complains
In file included from
lib/gcc/x86_64-pc-linux-gnu/8.0.0/../../../../include/c++/8.0.0/functional:60:
In file included from
lib/gcc/x86_64-pc-linux-gnu/8.0.0/../../../../include/c++/8.0.0/unordered_map:47:
lib/gcc/x86_64-pc-linux-gnu/8.0.0/../../../../include/c++/8.0.0/bits/unordered_map.h:1197:5:
error: deduction guide template contains a template parameter that cannot be
deduced
unordered_map(initializer_list<pair<_Key, _Tp>>, _Allocator)
^
lib/gcc/x86_64-pc-linux-gnu/8.0.0/../../../../include/c++/8.0.0/bits/unordered_map.h:1196:34:
note: non-deducible template parameter (anonymous)
_RequireAllocator<_Allocator>>
^
1 error generated.
Committed to trunk, backport to gcc-7-branch will follow.
I created https://gcc.gnu.org/PR83181 for the accepts-invalid bug. All
our tests pass with or without the fix, and even with that deduction
guide completely deleted, so I don't understand what it's supposed to
be for. This is hardly the only thing I don't understand about
deduction guides.