This is a Journal entry by Martin Harper
Why I love java
Martin Harper Started conversation Apr 2, 2001
My compiler complained at me recently: it said "AssignmentOperator AssignmentExpression not found". This was a new error message - but it turned out that instead of "for( int cand = 0 ; cand < scores.length ; cand++ ) {" I'd written "for( int cand = 0 ; cand < scores.length ; cand ) {".
Two missing '+' characters. In C I'd have got a warning if I was lucky - more likely the compiler would leave me quite happy to create a piece of code with no purpose whatsoever. In java I get told off, and I save a few minutes (or hours) debug time.
Others call it 'mollycoddling' and such - but me, I like it when the language stops me being an idiot. We're all human and fallible, and some days it seems like coders are more fallible than everyone else (not true: we just work to higher standards). I'll take all the cotton wool I can get, thanks.
Why I love java
Barton Posted Apr 11, 2001
I'm thinking about all the languages I have used (and I have never used Java -- I'm waiting for it to become obsolete, maybe I'll start learning it next week or so. ) And, none of them have had terribly good error handling AND been a very strong language.
Of course, I tend to find that I want to do something that the designer of the language never intended to allow to be done in 'his' language. The next steps in my programming process inevitably involves finding away around the limitations that really does work. . . eventually.
I am constantly twitting one of my friends and collegues who is a genuine programming genius and who prefers to program in C(something) about how it seems to be impossible to program anything useful in C without casting.
But I shouldn't complain because the only language I really LOVE programming in is Forth which no one will pay me to do because no one else could ever maintain my code. (Sheer ingratitude) The result, I haven't programed in Forth for centuries now and I can't understand my code either. The error handler is very good, though. It nearly always leaves you in the bad module with a sensible message.
I still remember, fondly, programming in assembler. The error messages were simple and direct because the things that could go wrong were simple and direct -- if it compiles, it either runs or crashes. If it runs, it sometimes does stuff you wanted it to do. (All right, I *said* sometimes.)
There are still things to be said for the various dialects of BASIC. Of course, most of those things either can't be said in polite company or begin with the word 'slow.' But, for all that, once it was compiled it usually ran fast enough or you hacked around the problem sections. The error handler was much more specific and the debugger on the more sophisticated dialects was very nice. It's even resonably portable (in the same sense that C is portable, not very if you are trying to do anything real) but it translates fairly well when it won't port (Okay. It nearly never ports, you end up emulating the old platform.)
But, let's recognize once and for all, that the neatest language is Cobol. Have you stopped laughing? I haven't. :D )
Choice of programming language is another one of those 'religious' issues that I generally refuse to discuss. So, let's pretend I didn't say anything here.
Barton
Key: Complain about this post
Why I love java
More Conversations for Martin Harper
Write an Entry
"The Hitchhiker's Guide to the Galaxy is a wholly remarkable book. It has been compiled and recompiled many times and under many different editorships. It contains contributions from countless numbers of travellers and researchers."