Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Keith Thompson <kst-u@mib.org> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: Can main() be called by itself? |
| Date | 2015-08-14 11:15 -0700 |
| Organization | None to speak of |
| Message-ID | <lnh9o1ag8g.fsf@kst-u.example.com> (permalink) |
| References | <39b9ef39-3874-4983-8165-035b51b78827@googlegroups.com> <1b7foy7bhj.fsf@pfeifferfamily.net> |
Joe Pfeiffer <pfeiffer@cs.nmsu.edu> writes:
[...]
> Without knowing what your code is supposed to do, I can't tell you how
> to make it do it. But the big problem with this code is that its
> recursion is infinite -- it will call itself, which will call itself,
> which will.... until you run out of memory.
[...]
With an implementation that does sufficiently clever tail-call
optimization, it might merely be an infinite loop that does not consume
unbounded memory.
--
Keith Thompson (The_Other_Keith) kst-u@mib.org <http://www.ghoti.net/~kst>
Working, but not speaking, for JetHead Development, Inc.
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Can main() be called by itself? fl <rxjwg98@gmail.com> - 2015-08-13 16:51 -0700
Re: Can main() be called by itself? Melzzzzz <mel@zzzzz.com> - 2015-08-14 01:58 +0200
Re: Can main() be called by itself? James Kuyper <jameskuyper@verizon.net> - 2015-08-13 23:32 -0400
Re: Can main() be called by itself? Keith Thompson <kst-u@mib.org> - 2015-08-14 11:14 -0700
Re: Can main() be called by itself? Joe Pfeiffer <pfeiffer@cs.nmsu.edu> - 2015-08-13 22:14 -0600
Re: Can main() be called by itself? Keith Thompson <kst-u@mib.org> - 2015-08-14 11:15 -0700
Re: Can main() be called by itself? gordonb.mj8yu@burditt.org (Gordon Burditt) - 2015-08-14 01:52 -0500
Re: Can main() be called by itself? Ben Bacarisse <ben.usenet@bsb.me.uk> - 2015-08-14 11:46 +0100
Re: Can main() be called by itself? James Kuyper <jameskuyper@verizon.net> - 2015-08-14 07:54 -0400
Re: Can main() be called by itself? Melzzzzz <mel@zzzzz.com> - 2015-08-14 14:19 +0200
Re: Can main() be called by itself? David Brown <david.brown@hesbynett.no> - 2015-08-14 14:50 +0200
Re: Can main() be called by itself? Malcolm McLean <malcolm.mclean5@btinternet.com> - 2015-08-16 10:39 -0700
Re: Can main() be called by itself? gazelle@shell.xmission.com (Kenny McCormack) - 2015-08-14 12:32 +0000
csiph-web