Tail recursion vs exceptions vs C++
Zack Weinberg
zack@codesourcery.com
Sat Oct 25 01:14:00 GMT 2003
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
More information about the Gcc
mailing list