https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122192

--- Comment #8 from Vincent X <gulackeg at gmail dot com> ---
(In reply to Jason Merrill from comment #6)
> A typename-specifier is a type-only context under
> https://eel.is/c++draft/temp.res.general#4.1 and so we should only find type
> names under https://eel.is/c++draft/basic.lookup.general#4 , so the patch
> for PR107773 seems wrong.
I believe *type-only context* and *type-only* lookup serve different purposes.
A dependent name inside a type-only context is assumed to be a type. However,
if its lookup finds a non-type name, we would get an error. OTOH, type-only
lookup (as in, e.g., base specifiers) gives us the privilege of ignoring
non-type names. In the end, we either find a type name or get a name-not-found
error.

Reply via email to