[EMAIL PROTECTED] said:
> Dalibor Topic wrote:
> > Can't we just use assertions for things that should never happen?

> In this case I think its better not to, because assertions may be
> disabled in production builds. 

Ah ... but we could avoid that by explicitly throwing AssertionError.

But my preference is to throw InternalError.  The current large scale
use of InternalError in Sun's implementation makes their javadoc wrong.
In the light of this, InternalError is in fact a good fit.

Aside: if you want Sun to fix their abuse of RuntimeException, it
has Bug/RFE Id: 5071860 on the Sun Bug Parade.  In a day or so you
should be able to see it / vote for it.

-- Steve






_______________________________________________
Classpath mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/classpath

Reply via email to