[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Stack Size?
From: |
Mikael Djurfeldt |
Subject: |
Re: Stack Size? |
Date: |
09 Aug 2002 15:48:22 +0200 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 |
address@hidden (Robert Uhl <address@hidden>) writes:
> Neil Jerram <address@hidden> writes:
> >
> > > I've re-written the function, but it seems to me that it'd perhaps
> > > make more sense for Guile to simply grow the stack until it runs
> > > out of memory. Is there a technical reason this doesn't happen?
> >
> > No idea, I'm afraid. Perhaps it's considered a good thing for a
> > language to allow applications to have a grip on their stack usage?
Guile is supposed to be "nice" towards novice users. Infinite
recursions is a very common error. Without a stack check, the effect
is that the machine freezes due to excessive swapping, preventing the
novice user from even examining what has happened.
> It seems to me somewhat broken that one must set a debug option
> explicitly off. Sort of a command-line switch --behave-yourself, when
> that should be the default behaviour. Certainly, stack size checks
> may be _very_ useful when testing code. But just as certainly, in
> production those same checks are a nuisance, and can cause code to
> break.
It's probably a bad idea to use large stacks in production code and,
if not, it's rather easy to set the option to whatever one wants.
Maybe the correct setting is a very large stack?
M