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

--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Nathan Sidwell <nat...@gcc.gnu.org>:

https://gcc.gnu.org/g:2e66e53b1efb98f5cf6b0a123990c1ca999affd7

commit r11-3436-g2e66e53b1efb98f5cf6b0a123990c1ca999affd7
Author: Nathan Sidwell <nat...@acm.org>
Date:   Thu Sep 24 06:17:00 2020 -0700

    c++: local-decls are never member fns [PR97186]

    This fixes an ICE in noexcept instantiation.  It was presuming
    functions always have template_info, but that changed with my
    DECL_LOCAL_DECL_P changes.  Fortunately DECL_LOCAL_DECL_P fns are
    never member fns, so we don't need to go fishing out a this pointer.

    Also I realized I'd misnamed local10.C, so renaming it local-fn3.C,
    and while there adding the effective-target lto that David E pointed
    out was missing.

            PR c++/97186
            gcc/cp/
            * pt.c (maybe_instantiate_noexcept): Local externs are never
            member fns.
            gcc/testsuite/
            * g++.dg/template/local10.C: Rename ...
            * g++.dg/template/local-fn3.C: .. here.  Require lto.
            * g++.dg/template/local-fn4.C: New.

Reply via email to