The following program...
int main()
{
int{1}.~int();
}
does not compile on (see conformance viewer):
clang++ trunk, with
-std=c++1zg++ trunk, with
-std=c++1zCL 19 2017
Introducing a type alias for int...
int main()
{
using X = int;
int{1}.~X();
}
...makes the program valid on all previously mentioned compilers, without warnings (see conformance viewer).
Why is a type alias required when invoking int's destructor? Is this because int is not a valid grammar element for a destruction invocation?