Hi, Cameron Clark!
On 27 Aug 97 20:20:53 you wrote to Anthony Tibbs
AT> Q. How do I change the stack size?
AT> A. The size of the stack of a Turbo C++ program is determined at
AT> run time by the global variable _stklen. To change the size
AT> to, for example, 10,000 bytes, include the following line in
AT> your program:
AT>
AT> extern unsigned _stklen = 10000;
In C++ it probably must be declared as extern "C" unsigned ...
CC> That's the strangest thing I've ever seen (runtime adjustment).
That's not runtime adjustment. The stack is allocated in the strtup code, and
uses the value in _stklen. Is you change it afterwards (say as first line in
main()) that will have no effect.
CC> Are there any sideffects to changing the variable at different
CC> places?
No side effect other than they both are ignored. :)
Paul
... Beware of programmers who carry screwdrivers
--- OS/2 Warp
---------------
* Origin: The FlintStones' Cave in BedRock (2:371/20)
|