Howard said:
:
An infinite loop is not a "crash".
That's like saying, "your car caught fire and burned up, Mr. Smith,
so we're sorry, but we can't pay on your claim; you're only insured
against actual CRASHES, not fires". In other words, it crashed.
Infinite _recursion_ would lead to a crash, but an infinite
loop simply loops. I've written programs that loop
forever (well, until I stop them anyway).
Yes: Firmware, and Microsoft Windows apps both "loop forever";
but the loop I demonstrated doesn't just "loop forever", it
does so in a way that precludes input, output, or breaking
out. You generally have to push the "Reset" button. In other
words, it crashed.
(I inadvertantly did that to an IBM 370 for an entire half hour
once. Boy was the sysop annoyed when he discovered the the
entire system had been doing nothing but running my loop for
30 minutes. Good thing they didn't charge me for the CPU time.)
What compiler does that?
VS 2003 reports "too many include files: depth = 1024".
Sounds like a pretty poorly written compiler if it can't
protect itself from the data it's processing.
The situation I describe will crash the preprocessor.
The program will never get to the compiler.
Compilers never see #include's. The preprocessor replaces
those (if it can) with the contents being #include'ed. If
it can't, it crashes, and the compiler never runs.
And compile-time problems are also not program crashes.
That's like saying, "I'm sorry, but we can't pay on your claim
because you crashed your car while it was still inside the car
lot you bought it from." In other words, it crashed.
There are many reasons, not just dumb mistakes. Removing a
required physical resource
Two people made dumb mistakes there: The person who removed
the resource, and the person who made the program so brittle
that the missing resource triggered a crash.
The user slammed the door into the computer, or the HD engineer
designed a flaky product. In other words, dumb mistakes.
The user ran a resource-hungry program on a machine with only
8MB of RAM. Dumb mistake.
In other words, someone made a dumb mistake, and cosmic rays
seemed a good thing to blame.
User forgot to use a surge protector and an UPS, and left his
machine running during a thunderstorm. Dumb mistake.
and even subtle mistakes that aren't "dumb" at all,
Yes, some mistakes are subtle. But most are more along
the lines of "what idiot wrote this stupid code??? Oh,
wait, that was me. Oops. How could I have made such
a dumb mistake?"
Any number of things might lead the system to determine
that a process is attempting an invalid operation,
and that it needs to shut down the offending process.
Yes, and nearly ALL of those "number of things" are do to
human error on someone's part. Not necessarily the programmer,
but usually so. Face it: to err is human; but to really foul
things up requires a computer and someone who believes they're
an expert (but who is really just a pert). ;-)
--
Cheers,
Robbie Hatley
Tustin, CA, USA
lonewolfintj at pacbell dot net
(put "[usenet]" in subject to bypass spam filter)
http://home.pacbell.net/earnur/