public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "martin at mpa-garching dot mpg dot de" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/22405] New: ICE in when instantiating a template function, for illegal code Date: Mon, 11 Jul 2005 09:53:00 -0000 [thread overview] Message-ID: <20050711095219.22405.martin@mpa-garching.mpg.de> (raw) Current g++ produces an ICE when compiling the following code snippet: template <typename T> void foo(T &arg) { arg+=1; } template <typename T> void foo(T &arg) { arg+=2; } template void foo(float &arg); ~/tmp>g++ -v bug.cc Using built-in specs. Target: i686-pc-linux-gnu Configured with: /scratch/gcc/configure --quiet --prefix=/afs/mpa/data/martin/ugcc --enable-languages=c++,f95 --enable-mapped-location --with-gmp=/afs/mpa/data/martin/mygmp Thread model: posix gcc version 4.1.0 20050711 (experimental) /afs/mpa/data/martin/ugcc/libexec/gcc/i686-pc-linux-gnu/4.1.0/cc1plus -quiet -v -D_GNU_SOURCE bug.cc -quiet -dumpbase bug.cc -mtune=pentiumpro -auxbase bug -version -o /tmp/cctt6fLt.s ignoring nonexistent directory "/afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.1.0/../../../../i686-pc-linux-gnu/include" #include "..." search starts here: #include <...> search starts here: /afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.1.0/../../../../include/c++/4.1.0 /afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.1.0/../../../../include/c++/4.1.0/i686-pc-linux-gnu /afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.1.0/../../../../include/c++/4.1.0/backward /usr/local/include /afs/mpa/data/martin/ugcc/include /afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.1.0/include /usr/include End of search list. GNU C++ version 4.1.0 20050711 (experimental) (i686-pc-linux-gnu) compiled by GNU C version 4.1.0 20050711 (experimental). GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096 Compiler executable checksum: 4d7d2981a00322530f4db8cbc706d5cf bug.cc:5:38: error: redefinition of 'template<class T> void foo(T&)' bug.cc:1:38: error: 'template<class T> void foo(T&)' previously declared here bug.cc:9:29: internal compiler error: Segmentation fault Please submit a full bug report, with preprocessed source if appropriate. See <URL:http://gcc.gnu.org/bugs.html> for instructions. -- Summary: ICE in when instantiating a template function, for illegal code Product: gcc Version: 4.1.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: martin at mpa-garching dot mpg dot de CC: gcc-bugs at gcc dot gnu dot org,martin at mpa-garching dot mpg dot de GCC build triplet: i686-pc-linux-gnu GCC host triplet: i686-pc-linux-gnu GCC target triplet: i686-pc-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22405
next reply other threads:[~2005-07-11 9:52 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2005-07-11 9:53 martin at mpa-garching dot mpg dot de [this message] 2005-07-11 10:47 ` [Bug c++/22405] " martin at mpa-garching dot mpg dot de 2005-07-11 14:42 ` [Bug c++/22405] [4.1 Regression] " pinskia at gcc dot gnu dot org 2005-07-11 15:58 ` pinskia at gcc dot gnu dot org 2005-07-11 16:02 ` pinskia at gcc dot gnu dot org 2005-07-25 13:41 ` [Bug c++/22405] [4.0.1/4.1 " reichelt at gcc dot gnu dot org 2005-07-25 13:54 ` reichelt at gcc dot gnu dot org 2005-09-27 15:59 ` mmitchel at gcc dot gnu dot org
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=20050711095219.22405.martin@mpa-garching.mpg.de \ --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).