This post originated from an RSS feed registered with Ruby Buzz
by Rick DeNatale.
Original Post: Crash!
Feed Title: Talk Like A Duck
Feed URL: http://talklikeaduck.denhaven2.com/articles.atom
Feed Description: Musings on Ruby, Rails, and other topics by an experienced object technologist.
Recently posted on Ruby Talk, under the title ‘This System Must have been Written in Ruby’
At 1950 feet (around 700 meters) the airplane’s left altimeter
suddenly and mistakenly registered an altitude of 8 feet (about
2 meters) below sea level and passed the reading on to the
automatic control system, Van Vollenhoven said.
But the autopilot reduced gas to the engines and the plane lost
speed, decelerating until, at a height of 450 feet (150 meters)
it was about to stall. Warning systems alerted the pilots.
It appears that then the pilots immediately gave gas, full
gas, however it was too late to recover,’’ ...The plane fell
into a freshly plowed field, striking the ground tail first and
breaking into three pieces.
I assume the poster’s position is that this is the kind of thing that happens when non-statically typed languages are used to implement mission critical functions.
I use to hear the same argument about C++ vs Smalltalk, from no less a luminary than Bjarne Stroustrup, who was wont to say that he would hate to fly in an airplane whose autopilot might throw a doesNotUnderstand: exception because of a type violation.
Okay, I admit it, the static type zealots are correct. Static typing absolves the programmer from worrying about:
Conceptual errors in the domain model.
The fact that a floating point number is a poor approximation of a real number.
Incorrect mathematical formulae, either due to misunderstanding, or typos.
User errors.
Off by one errors
Buffer overflows
Bad input data
Adding instead of subtracting, or vice-versa
Hardware failures
Errors in concurrency control
Your favorite bug here
The need to properly test the system.
If you believe that, or any significant portion of it, let me tell you about this bridge between Brooklyn and Manhattan which I have to sell you!
And if you believe that and rely on that faith to implement mission critical systems, please feature it in your advertisements, and let us know what mission critical systems were built that way, so that the rest of us can avoid them whenever possible.