Open MitalAshok opened 3 months ago
@llvm/issue-subscribers-clang-frontend
Author: Mital Ashok (MitalAshok)
https://eel.is/c++draft/temp.names#3
A
<
is interpreted as the delimiter of a template-argument-list if it follows a name [...] that is [...] in a type-only context other than a nested-name-specifier.This wording was added by P1787R6 for C++23
These parts of changes seem to be the resolution of CWG1478 but touch more things than the original issue.
Edit: Is this already tracked in #54150?
@frederick-vs-ja I don't think this is related to CWG1478 because that's specifically about when there isn't a <
.
Reading P1787P6§Parsing makes it seem like type-only contexts (previously: type-id-only contexts, in Clang as ImplicitTypenameContext
) were extended to include "implicit template
" that doesn't seem to be mentioned in #54150.
This might be a dup of #95447
https://eel.is/c++draft/temp.names#3
This wording was added by P1787R6 for C++23
https://godbolt.org/z/GanbhKTh1
Last two are valid after https://cplusplus.github.io/CWG/issues/2806.html and https://cplusplus.github.io/CWG/issues/2903.html
This compiles with
-fms-extensions
.MSVC only compiles this with
/permissive
(not/permissive-
):GCC compiles it all.