- priority: 5 --> 1
It is nice to program without having to write "throws
WhateverException" in Nice. But, when using Nice from
Java, there happen to be at least two inconveniences:
1) I can no longer write
... }catch( java.io.FileNotFoundException noSuchFile ){ ...
whithout being warned by the Eclipce compiler that
"Unreachable catch block for FileNotFoundException.
This exception is never thrown from the try statement
body".
And it is not even clear to me, will the Exception
still be catched, or is it wrapped into something.
2) When a Java class extends a Nice class, it can no
longer throw normal exceptions, becouse "Exception
FileNotFoundException is not compatible with throws
clause in NiceClass.niceMethod()".
The best way to deal with it is perhaps an automatic
"throws" deduction (which some Java compilers seems to
do anyway, if only to issue warnings), but I ask merely
for basic "throws" clause to be accepted by the Nice
compiler and propagated to Java-visible methods. It
will even ease to some small extent the porting of Java
source to the Nice.