With the StackOverflowException are the conditions to be thrown hardcoded or dependent on the machine the code is running on?
I am almost certain the latter but have failed in my searches and don't ask enough questions here.
From the documentation:
... is thrown when the execution stack overflows because it contains too many nested method calls.
Since the size of the stack is architecture-dependent and can even be overridden on a machine, yes, this value is not hard-coded, though it is generally pretty static on Windows. If I remember correctly, it is 1MB in size by default.
Although not a perfect match for your question, see also:
How do you change default stack size for managed executable.net
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With