This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Tail recursion vs exceptions vs C++
- From: "Zack Weinberg" <zack at codesourcery dot com>
- To: Iain McClatchie <iain at truecircuits dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Fri, 24 Oct 2003 13:54:24 -0700
- Subject: Re: Tail recursion vs exceptions vs C++
- References: <3F998EE6.7EF604E6@truecircuits.com>
Iain McClatchie <iain@truecircuits.com> writes:
> queue21 (try) [6] % gcc tail.cc
> /tmp/ccgYrf4b.o(.eh_frame+0x11): undefined reference to `__gxx_personality_v0'
> collect2: ld returned 1 exit status
You must either use g++ for the link operation, or add -lstdc++ to the
command line. (Patches to augment collect2 and/or GNU ld so that this
is not necessary are welcome.)
I very much doubt this has anything to do with recursion, tail or
otherwise, except perhaps insofar as GNU C++ is clever enough to
realize that no exception handling information is necessary for
int main(void) {}
but not
int main(void) { main(); }
zw