🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #75542

Re: Why does Java require the throws clause? Good or bad language design?

#75542
From: Harvey
Date: Mon, 12 Mar 2007 19:28
60 lines
3580 bytes
In article <20070208134827.GC5007@morgenes.shire.sytes.net>, Robbert Haarman
<comp.lang.misc@inglorion.net> wrote:
>On Thu, Feb 08, 2007 at 07:52:40AM -0500, Lew wrote:
>> Bent C Dalager wrote:
>> >>And, of course,
>> >>public void foo(Object... args) throws Throwable
>> >>may be just the silver bullet we are looking for . . .
>>
>> Robbert Haarman wrote:
>> >In the end, you get the worst of
>> >dynamic typing and the worst of mandatory declarations, all in one
>> >program.
>>
>> Which is why newsgroup readers have to watch out for humorous replies, and
>> not try actually to implement them.
>
>Point taken.
>
>On the other hand, people do actually write code like that. Well.
>perhaps not "throws Throwable", but certainly "throws Exception".

Not much different from throws Throwable
as you loose any and all the precision.
Basically, your program is screwed beyond repair
and the entire exceptions mechanism needs to be redesigned.

>And
>anyone who has been programming in Java for some time will have seen the
>likes of
>
>void add(Object o) ...
>
>and
>
>((SomeClass) someContainer.get(someKey)).someMethod(...)
>
>It's not just misguided programmers that write such code; Java was full
>of it before the type system overhaul.
>
>Regards,
>
>Bob
>




- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"It would be a mistake for the United States Senate
to allow any kind of human cloning to come out of
that chamber."

--- Adolph Bush,
    Washington, D.C., April 10, 2002

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
This is just a reminder.
It is not an emergency yet.
Were it actual emergency, you wouldn't be able to read this.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Technical Details
Message-ID: <1pu5we$0gy$0@excite.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!number1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!news.glorb.com!solnet.ch!solnet.ch!82.144.192.35.MISMATCH!volia.net!news2.volia.net!news.ntu-kpi.kiev.ua!news.uran.net.ua!news1.lucky.net!carrier.kiev.ua!news.te.net.ua!postnews.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx02.iad01.newshosting.com!newshosting.com!130.81.64.211.MISMATCH!cycny01.gnilink.net!spamkiller2.gnilink.net!gnilink.net!trndny04.POSTED!760c3fd9!sprintmail.com!greek
References: <1170835862.972715.24740@v33g2000cwv.googlegroups.com> <45c9a593$0$765$5a6aecb4@news.aaisp.net.uk> <gcudnTZig-sMTFTYnZ2dnUVZ_uGjnZ2d@comcast.com> <eqeuu2$tec$1@orkan.itea.ntnu.no> <20070208111322.GB5007@morgenes.shire.sytes.net> <edCdnWnpjsCLgFbYnZ2dnUVZ_vDinZ2d@comcast.com> <20070208134827.GC5007@morgenes.shire.sytes.net>

Show Full Headers
Complete Article Headers
Message-ID: <1pu5we$0gy$0@excite.com>
Subject: Re: Why does Java require the throws clause? Good or bad language design?
Date: Mon, 12 Mar 2007 19:28:19 GMT
From: Harvey <greek@sprintmail.com>
References: <1170835862.972715.24740@v33g2000cwv.googlegroups.com> <45c9a593$0$765$5a6aecb4@news.aaisp.net.uk> <gcudnTZig-sMTFTYnZ2dnUVZ_uGjnZ2d@comcast.com> <eqeuu2$tec$1@orkan.itea.ntnu.no> <20070208111322.GB5007@morgenes.shire.sytes.net> <edCdnWnpjsCLgFbYnZ2dnUVZ_vDinZ2d@comcast.com> <20070208134827.GC5007@morgenes.shire.sytes.net>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!number1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!news.glorb.com!solnet.ch!solnet.ch!82.144.192.35.MISMATCH!volia.net!news2.volia.net!news.ntu-kpi.kiev.ua!news.uran.net.ua!news1.lucky.net!carrier.kiev.ua!news.te.net.ua!postnews.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx02.iad01.newshosting.com!newshosting.com!130.81.64.211.MISMATCH!cycny01.gnilink.net!spamkiller2.gnilink.net!gnilink.net!trndny04.POSTED!760c3fd9!sprintmail.com!greek
Newsgroups: news.groups, alt.slack, alt.config, news.software.nntp, alt.usenet.kooks
 alt.usenet.kooks
Organization: Amputated Intelligence Enterprises
Lines: 60
Approved: ceo@big8.orgy (Big-8 CEO)
NNTP-Posting-Host: d134-75.tenet.odessa.ua
X-Trace: toster.te.net.ua 1173743727 32039 195.138.75.134 (12 Mar 2007
X-Complaints-To: abuse@te.net.ua
NNTP-Posting-Date: Mon, 12 Mar 2007 23:55:27 +0000 (UTC)
X-Newsreader: Microsoft Outlook Express 4.72.3110.1