stack overflow

S

swesoc

Hello Friends,

Assume, If i write a recerive function that goes in an infinite loop &
exceeds the limit of stack

I know it gives 'stack overflow' but other then what happens internally
 
S

Someonekicked

the hardrive starts shouting too loud, the processor might get out of
control and shoot all requests.
someone might get hurt...
 
A

Alf P. Steinbach

* swesoc:
Assume, If i write a recerive function that goes in an infinite loop &
exceeds the limit of stack

Presumably you mean an infinite recursion.

I know it gives 'stack overflow' but other then what happens internally

How many tails has a dog? That depends on the dog. Post code.
 
N

Niels Dybdahl

Assume, If i write a recerive function that goes in an infinite loop &
exceeds the limit of stack

I know it gives 'stack overflow' but other then what happens internally

Some compilers might create code that throws an exception, which can be
caught. Other compilers just create code that crashes the whole application.
It is a very tricky error to handle, because there is no more stack space
for the error handling code.

Niels Dybdahl
 
R

red floyd

Someonekicked said:
the hardrive starts shouting too loud, the processor might get out of
control and shoot all requests.
someone might get hurt...
Don't forget:

Fire and brimstone coming down from the skies. Rivers and seas boiling.
Forty years of darkness. Earthquakes, volcanoes...
The dead rising from the grave.
Human sacrifice, dogs and cats living together - mass hysteria!
 
C

Csaba

Don't forget:

Fire and brimstone coming down from the skies. Rivers and seas boiling.
Forty years of darkness. Earthquakes, volcanoes...
The dead rising from the grave.
Human sacrifice, dogs and cats living together - mass hysteria!

You forgot :

Demons coming out of your nose (if stack overflow counts as Undefined
Behaviour).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,571
Members
45,045
Latest member
DRCM

Latest Threads

Top