commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Cooper <mfncoo...@gmail.com>
Subject Re: Worst offence in Java :) Re: [lang] Interpolation
Date Sun, 29 Aug 2004 16:56:35 GMT
MUCH worse would be returning from a 'finally' clause, which can cause
unexpected control flow behaviour. See "The Java Hall of Shame":

http://www.cs.arizona.edu/sumatra/hallofshame/

and also "The Lost Exception" in Bruce Eckel's "Thinking in Java".

--
Martin Cooper


On Sun, 29 Aug 2004 02:12:37 -0400 (EDT), Henri Yandell
<bayard@generationjava.com> wrote:
> 
> On Sat, 28 Aug 2004, matthew.hawthorne wrote:
> 
> > > IMO, copy-paste reuse is the worst offense that a programmer can commit.
> >
> > I agree that it's bad news.
> >
> > But, I think the worst offense is this:
> >
> > try {
> >
> >    // ...
> >
> > } catch (Exception e) {
> >    return null;
> > }
> >
> > (shudder)
> 
> How lucky you've been. Have you never seen:
> 
> try {
>    ...
> } catch(Throwable t) {
>    // ignore
> }
> 
> ??? :)
> 
> Hen
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message