commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From netomi <...@git.apache.org>
Subject [GitHub] commons-lang pull request: Ability to throw checked exceptions wit...
Date Sat, 20 Jun 2015 15:41:47 GMT
Github user netomi commented on the pull request:

    https://github.com/apache/commons-lang/pull/98#issuecomment-113783523
  
    My bad, I missed that the type argument will get erased, but in fact this makes it even
worse. With this method you can outwit the compiler, throwing a checked exception further
up the stack, leading to situations where code that would never expect a checked exception
force to handle it.
    
    I would prefer to explicitly throw the checked exception wrapped in a RuntimeException
as guava does in its Throwables class.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message