This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: C++ PATCHes to dependent template-id parsing


On Wed, Jun 28, 2017 at 3:38 PM, Jason Merrill <jason@redhat.com> wrote:
> 81204 is a regression whereby previously we would accidentally get the
> parsing of res.template set<I> right because when we did the lookup in
> the surrounding context, we found the function template and then
> ignored it.  This patch partially reverts the handling of .template to
> how it was in GCC 6.
>
> But this bug is really a special case of 54769; we should be treating
> that name as dependent and not doing a lookup in the enclosing context
> at all.  As I noted in discussion of 55576, we need to pass
> template_keyword_p into nested_name_specifier_opt.  So this patch does
> that, and also adjusts cp_parser_template_name to consider object
> scope.

I'm reverting the 81204 patch for both 7 and 8, as it is wrong under
DR 141 and the 54769 patch is better.

Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]