Re: Unchecked exceptions for IO considered harmful.

2016-08-15 Thread Carlos Barrera
What? Is a mechanical invention device. 2016-08-15 16:48 GMT-05:00 Martin Thompson : > This thread is now way off the topic of mechanical sympathy. > > Please lets keep it focused. > > Martin... > > -- > You received this message because you are subscribed to the Google Groups

Re: Unchecked exceptions for IO considered harmful.

2016-08-15 Thread Martin Thompson
+1 On 15 August 2016 at 15:05, Avi Kivity wrote: > Perhaps this discussion should be moved to a Java group. As far as I can > tell, it has nothing to do with mechanical sympathy. > -- You received this message because you are subscribed to the Google Groups

Re: Unchecked exceptions for IO considered harmful.

2016-08-15 Thread Avi Kivity
Perhaps this discussion should be moved to a Java group. As far as I can tell, it has nothing to do with mechanical sympathy. On 08/15/2016 05:00 PM, Vitaly Davidovich wrote: Why is it egregious? It's detailed in the types of exceptions it throws, yes, but that's good assuming you want to

Re: Unchecked exceptions for IO considered harmful.

2016-08-15 Thread Vitaly Davidovich
Why is it egregious? It's detailed in the types of exceptions it throws, yes, but that's good assuming you want to handle some of those types (and there are cases where those exceptions can be handled properly). Even before ReflectiveOperationException, you could use multi-catch since Java 7 to

Re: Unchecked exceptions for IO considered harmful.

2016-08-15 Thread Eric DeFazio
IMHO the most egregious use of ChekedExceptions is in Javas Reflection API, and I cry when I think how beautiful it could have been verses how cumbersome reflection can be (My SmallTalk friends laugh about it) (To construct an instance of an object and then call a method on it) try {

Re: Unchecked exceptions for IO considered harmful.

2016-08-13 Thread Henri Tremblay
In fact, my guess is that you have checked exception haters that will not stop complaining unless you use unchecked exceptions. Then, you won't find much checked exception lovers. We will find some "I think they can be useful" (like me) and that won't complain too much if unchecked exception are

Re: Unchecked exceptions for IO considered harmful.

2016-08-13 Thread Dan Eloff
One can also look at how other statically typed languages since Java implement exceptions. There's Anders Hejlsberg and Bruce Eckel discussing why C# doesn't have checked exceptions: http://www.artima.com/intv/handcuffs.html Go (and it seems to me Rust as well) use explicit error returns for

Re: Unchecked exceptions for IO considered harmful.

2016-08-13 Thread João Nuno Silva
This page explains aws sdk reasoning: http://docs.aws.amazon.com/AWSSdkDocsJava/latest/DeveloperGuide/java-dg-exceptions.html On Aug 13, 2016 9:30 PM, "Kevin Burton" wrote: > > Thanks. I've already read the above. What's disturbing about these for me is that major

Re: Unchecked exceptions for IO considered harmful.

2016-08-13 Thread Kevin Burton
Thanks. I've already read the above. What's disturbing about these for me is that major driver frameworks like Elasticsearch and Cassandra have adopted unchecked exceptions without actually explaining the rational behind their decision. If you are a fan of unchecked exceptions, fine , please

Re: Unchecked exceptions for IO considered harmful.

2016-08-12 Thread Henri Tremblay
That's a big ongoing discussion. You can read an old blog post from Brian Goetz which is mostly a fan (at least in 2007) of checked exception but pointing out that is was causing some ugly code. It has highly improved in JDK 7 and 8.