Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
3.14.0
-
None
Description
I have been doing pass over deprecated warning in our code and one of them is that org.apache.commons.lang3.exception.ExceptionUtils#rethrow is deprecated. Its comment says "Use asRuntimeException(Throwable)." However, asRuntimeException() is not a good replacement. It lacks the generic type parameter R that the rethrow method has. In fact, the comment that says...
Returns: Never actually returned, this generic type matches any type which the calling site requires. [..]
...is lying.