POV-Ray : Newsgroups : povray.off-topic : Curious C / C++ defined behavior question : Re: Curious C / C++ defined behavior question Server Time
30 Jul 2024 00:30:22 EDT (-0400)
  Re: Curious C / C++ defined behavior question  
From: Darren New
Date: 29 Jun 2011 21:37:12
Message: <4e0bd348$1@news.povray.org>
On 6/29/2011 12:55, Warp wrote:
>    You can't impose a minimum amount of recursions because it depend on the
> size of the stack and how much stuff is allocated on it. You can allocate
> such a huge array on the stack that you might not be able to recurse even
> once without running out of stack space, regardless of how large the stack
> is.

That's why I thought maybe imposing a minimum stack size in bytes would work 
out better. Of course, compilers wouldn't become non-standard to support 
this - they'd just have to allocate big locals somewhere other than the 
stack, which is of course a bad idea for any reason other than compatibility 
with lame requirements. :-)

-- 
Darren New, San Diego CA, USA (PST)
   "Coding without comments is like
    driving without turn signals."


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.