On 11/28/18 10:48 AM, Marek Polacek wrote:
Since P0846R0 was implemented, a name will be treated as a template-name when
it is an unqualified-id followed by a < and name lookup finds either one or
more functions or finds nothing, in order to potentially cause ADL to be 
performed.

In this case, we had

   f<T> ();

where we'd found a decl for f (not a TEMPLATE_DECL) and < follows.

From the backtrace in the PR, it seems as though we're treating f<T> as non-dependent, which is wrong. type_dependent_expression_p only looks at the arguments of a TEMPLATE_ID_EXPR if it has unknown_type_node, so we probably want to give it that type.

Jason

Reply via email to