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]

[C++ Patch] PR 60999


Hi,

this regression unfortunately has to do with my fix for c++/57887, thus the code in maybe_begin_member_template_processing:

   if (nsdmi)
     decl = (CLASSTYPE_TEMPLATE_INFO (DECL_CONTEXT (decl))
         ? CLASSTYPE_TI_TEMPLATE (DECL_CONTEXT (decl))
         : NULL_TREE);

The check is true for the new testcase and we end up with an unsubstituted STATIC_CAST_EXPR which leads to an ICE in cxx_eval_constant_expression. Having tried a number of ideas (by now we have got quite a few testcases in this area), I think it makes sense to check uses_template_parms too on DECL_CONTEXT (decl): when it returns false I don't think we may run into uses of template parms a la c++/57887 and we are back to the status pre- that fix in nsdmi handling.

Tested x86_64-linux.

Thanks,
Paolo.

/////////////////////


Attachment: CL_60999
Description: Text document

Attachment: patch_60999
Description: Text document


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