Dimitris Vyzovitis wrote:
>
> SHUDO Kazuyuki wrote:
>
> > > Personally I prefer explicit checks.
> >
> > Why?
> >
>
> I am also tempted to ask why....
> Is there any particular reason to add client side check for what the VM does on
> its own?
> I personally think that there is no need to do explicit checks in your code
> (it is inherently suboptimal) and let the VM do its work - just add the
> required exception handlers ;-}.
My interpretation, after a couple of re-readings :-), was that this
meant a preference for explicit checks in the JVM code instead of using
underlying OS facilities (signals). Why? Simplifies implementation. Why
not? Bad news for JVM performance.
As for what happens on the application side: exceptions are expensive.
Setting up try{} blocks is expensive, and triggering an exception is
really expensive. Exceptions should handle exceptional (for example,
unexpected) conditions, not normal conditions such as detecting EOF or
exhaustion of an iterator.
Nathan
----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]