469,574 Members | 1,643 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,574 developers. It's quick & easy.

g++ and tail recursion

We have been studying tail recursion in my computer class. The prof
told us that some compilers will turn a tail recursion into an
iteration thus allowing many, many function calls to the recursion. I
have proved to myself that the two flavors of VC++ I have will do this
but I cannot get the GNU G++ compiler to do so. It is run in unix on
a sun sparc and is version 3.3.2. It's threading is POSIX. Is there
a switch which will compile a tail recursion on g++ as an iteration?
Ray Wesley Kinserlow Jr.
Lubbock, Texas
rkinserlow at cox dot net
homepage: www.members.cox.net/rkinserlow
Mar 5 '06 #1
0 1653

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

10 posts views Thread by Christopher T King | last post: by
4 posts views Thread by Crutcher | last post: by
19 posts views Thread by Kay Schluehr | last post: by
11 posts views Thread by Josiah Manson | last post: by
35 posts views Thread by Muzammil | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.