(T())(foo) is a cast expression because T()
is treated as a type-id, and the expression is valid.
However, (T())(foo...) is not a valid cast-expression,
because (type-id)(foo...) is invalid.
Yet, it is a valid postfix expression, ie,
T().operator()(foo...)
We previously would uncontitionally consider the whole thing
a cast expression and complained about expecting a
right parenthesis after foo.
We do keep track of whether we are in a context where the
type-id is ambiguous to keep the existing diagnostics for
the non ambiguous case (ie (void)(foo...)).
Fixes #64926