Test code (CE):
struct A {
int a;
};
struct B {
int b;
};
template <A> void f();
template <B> void f();
// ✓ - GCC/Clang: OK
// ✗ - EDG:
// - error: expected an expression
// - error: expected a ")"
// ✗ - MSVC: https://developercommunity.visualstudio.com/t/Using-an-initializer-list-as-a-template/10994813
using T1 = decltype(f<{.a = 42}>());
using T2 = decltype(f<A{.a = 42}>()); // OK
// ✓ - GCC: OK
// ✗ - Clang:
// - error: call to 'f' is ambiguous
// - note: candidate function [with $0 = A{0}]
// - note: candidate function [with $0 = B{42}]
// ✗ - EDG/MSVC: same as for `T1` above
using T3 = decltype(f<{.b = 42}>());
using T4 = decltype(f<B{.b = 42}>()); // OK