public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "bangerth at dealii dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/14389] Can't define inline overloaded template function members out of their class. Date: Tue, 02 Mar 2004 19:49:00 -0000 [thread overview] Message-ID: <20040302194911.21700.qmail@sources.redhat.com> (raw) In-Reply-To: <20040302191442.14389.fasbjx@free.fr> ------- Additional Comments From bangerth at dealii dot org 2004-03-02 19:49 ------- Confirmed: -------------------- struct S { template< typename B, typename A > void foo(); template< typename A > void foo(); }; template< typename A > void S::foo() {} template< typename B, typename A > void S::foo() {} template void S::foo<void> (); template void S::foo<void,void> (); ------------------------- This fails with 3.3.4, 3.4 and mainline and all other versions I have here: g/x> /home/bangerth/bin/gcc-3.5-pre/bin/c++ -c x.cc x.cc:18: error: redefinition of `void S::foo()' x.cc:14: error: `void S::foo()' previously declared here x.cc:18: error: got 2 template parameters for `void S::foo()' x.cc:18: error: but 1 required x.cc:14: internal compiler error: tree check: accessed elt 2 of tree_vec with 1 elts in tsubst, at cp/pt.c:6729 Please submit a full bug report, The last example also fails, but for the sake of having only one problem per report I'll submit it in another PR. W. -- What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever Confirmed| |1 Known to fail| |2.95.3 3.2.3 3.3.3 3.4.0 | |3.5.0 Last reconfirmed|0000-00-00 00:00:00 |2004-03-02 19:49:08 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14389
next prev parent reply other threads:[~2004-03-02 19:49 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2004-03-02 19:14 [Bug c++/14389] New: " gcc-bugzilla at gcc dot gnu dot org 2004-03-02 19:49 ` bangerth at dealii dot org [this message] 2004-03-02 19:52 ` [Bug c++/14389] Out-of-line of overloaded template rejected bangerth at dealii dot org 2004-03-02 20:25 ` pinskia at gcc dot gnu dot org 2004-03-03 13:44 ` giovannibajo at libero dot it 2004-03-03 13:44 ` giovannibajo at libero dot it 2004-03-03 17:07 ` giovannibajo at libero dot it 2004-03-03 18:26 ` giovannibajo at libero dot it 2004-05-03 10:11 ` cvs-commit at gcc dot gnu dot org 2004-05-03 10:16 ` giovannibajo at libero dot it
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20040302194911.21700.qmail@sources.redhat.com \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).