Re: D gets it right

From: Mark 'Kamikaze' Hughes (kamikaze_at_kuoi.asui.uidaho.edu)
Date: 02/13/04


Date: 13 Feb 2004 00:40:02 GMT

Joe \"Nuke Me Xemu\" Foster <joe@bftsi0.UUCP>
wrote on Thu, 12 Feb 2004 13:34:30 -0800:
> The current 'best practice' seems to be to throw an exception in
> the finalizer in order to crash the program with an unfriendly
> diagnostic message. Of course, since Java is no longer guaranteed
> to even call pending finalizers on normal program exit, this is
> even farther from a 'panacea' than it first appears.

  Finalizers never worked reliably in Java, and anyone who relied on
them was writing bad code in defiance of the documentation and all
accepted practice. It would be nice if they had been functional, at
least at program close, but that's not the case. But what is it that
you'd prefer a language to do when an exception occurs in a finalizer?
Trap and display it, and continue on to the next 10000 identical objects
which will also fail? That sounds like a cunning and very
developer-friendly solution. Please demonstrate this technique in your
language so we can all observe how useful it is.

> And the Java
> bigots wonder why Visual Basic was one of the most popular languages
> before Micro$haft killed it in favor of their buggered Java clones!

  I'm fairly described as a Java bigot[0], and I don't wonder that about
VB at all. VB was a brain-damaged[1] language designed to allow
non-programmers to attach 10k of broken code to a GUI button, or to
create the exciting new field of email viruses. It filled the niche
that Hypercard did on the Mac, but with Microsoft's usual standard of
ease of use and quality instead of Apple's. Its popularity among
Windoze users is completely unsurprising.

[0] Really, more of a "good languages bigot". I'm perfectly happy with
Python, PHP, OCaml, and several other languages. With time and some
practical examples of its use, D may well join that list.
[1] "It is practically impossible to teach good programming to students
that have had a prior exposure to BASIC: as potential programmers they
are mentally mutilated beyond hope of regeneration."
-Prof. Dr. Edsger W. Dijkstra
I don't fully agree with the good professor. I do believe it's possible
to recover from bad programming languages. I certainly hope so, since I
was raised on BASIC, before learning better.

-- 
  Mark Hughes 
"God, I think. God. He doesn't answer, and I'd be justifiably scared--but not
 in a panic!--if he did, since I would know it really was Resuna, or a tiny
 brain tumor, or some boo-boo in my mix of neurotransmitters." -John Barnes


Relevant Pages

  • Re: Dareshimo
    ... That's not a hard gap to make up if you concentrate on the Practice ... have good enough language proficiency to pass. ... preparation and strategy guide put out by ALC. ... versions of the tapes. ...
    (sci.lang.japan)
  • Re: Delphi vs Web/Scripting Languages
    ... The gap between the best software engineering practice ... imposed by a tool or language, but is more likely to be encouraged by a community. ... And if this compiler is made x-platform thing which is certainly doable, and it was done by several projects already (I don't mean now Delphi necessarily) then where is the advantage of the family of languages which you support? ...
    (borland.public.delphi.non-technical)
  • Re: FORSTY - The Fortran Styler :-)
    ... I just took this from the F language. ... or that experienced users who write well should not be able to ... but will decide what is good practice or bad practice. ... I will use my company standards for such things which by-committee of CS-degree types decides that some of the recommendations of F are unacceptable. ...
    (comp.lang.fortran)
  • Re: What is C suitable for nowadays?
    ... projects to practice myself. ... Small physical size of the book "The C Programming Language", ... at least I found that it is too complicated for a beginner like ...
    (comp.lang.c)
  • Re: What, exactly, is Apples iPod business model?
    ... It isn't a programming language ... You can simulate any special-purpose Turing Machine with Cobol or any ... "Computer science" became an attempt to separate theory from practice ...
    (comp.sys.mac.apps)