https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104691
--- Comment #6 from CVS Commits ---
The trunk branch has been updated by Jason Merrill :
https://gcc.gnu.org/g:9944ca17c0766623bce260684edc614def7ea761
commit r13-6133-g9944ca17c0766623bce260684edc614def7ea761
Author: Jason Merrill
Date: Fr
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104691
--- Comment #5 from Jonathan Wakely ---
N.B. this has nothing to do with SFINAE. The static_assert fails when the
template is first parsed *not* when instantiated. You can verify this easily:
template
typename T::bar
f(T) { static_assert(false,
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104691
--- Comment #4 from Jonathan Wakely ---
Reduced:
template
typename T::foo
f(T) { }
template
typename T::bar
f(T) { static_assert(false, ""); }
struct X { using foo = void; };
int main()
{
X x;
f(x);
}
All compilers reject this code.
S
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104691
Jonathan Wakely changed:
What|Removed |Added
Resolution|--- |INVALID
Status|UNCONFIRME
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104691
--- Comment #2 from Andrew Pinski ---
The unincluded source:
#include
#include
#include
template
std::enable_if_t
MakeFilled(const typename
std::remove_reference::type & value)
{
TContainer result{};
std::fill(result.begin(), result.end
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104691
--- Comment #1 from Leengit ---
Closely related bug: although not demonstrated in the supplied code, note that
compilation should complete successfully even if the static_assert fails to
compile because its first argument is not `constexpr` give