This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/78948] [C++17] constexpr if instantiating too eagerly
- From: "jakub at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 05 Jan 2017 11:48:20 +0000
- Subject: [Bug c++/78948] [C++17] constexpr if instantiating too eagerly
- Auto-submitted: auto-generated
- References: <bug-78948-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78948
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
During parsing, we call mark_used on the function to call, which in turn does
instantiate_decl -> add_pending_template.
So, shall we avoid calling mark_used from parser->in_discarded_stmt (we'd need
to propagate that flag down to call.c), something different?