You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
template<class> structX {};
template<class=void> structX;
X x;
Accepted by GCC and MSVC, rejected by Clang:
<source>:4:3: error: no viable constructor or deduction guide for deduction of template arguments of 'X'
4 | X x;
| ^
<source>:1:24: note: candidate template ignored: couldn't infer template argument ''
1 | template<class> struct X {};
| ^
<source>:1:24: note: candidate function template not viable: requires 1 argument, but 0 were provided
1 | template<class> struct X {};
| ^
1 error generated.
Compiler returned: 1
This affects <memory_resource> in GCC 13's libstdc++, which defines polymorphic_allocator first before adding a default template argument in a later declaration.
The text was updated successfully, but these errors were encountered:
```cpp
template<class> struct X {};
template<class=void> struct X;
X x;
Accepted by GCC and MSVC, rejected by Clang:
<source>:4:3: error: no viable constructor or deduction guide for deduction of template arguments of 'X'
4 | X x;
| ^
<source>:1:24: note: candidate template ignored: couldn't infer template argument ''
1 | template<class> struct X {};
| ^
<source>:1:24: note: candidate function template not viable: requires 1 argument, but 0 were provided
1 | template<class> struct X {};
| ^
1 error generated.
Compiler returned: 1
This affects `<memory_resource>` in GCC 13's libstdc++, which defines `polymorphic_allocator` first before adding a default template argument in a later declaration.
</details>
Accepted by GCC and MSVC, rejected by Clang:
This affects
<memory_resource>
in GCC 13's libstdc++, which definespolymorphic_allocator
first before adding a default template argument in a later declaration.The text was updated successfully, but these errors were encountered: