[ 
https://issues.apache.org/jira/browse/MATH-856?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13451111#comment-13451111
 ] 

Phil Steitz commented on MATH-856:
----------------------------------

Then lets leave things as is.  I do not want to reduce robustness in places 
where we document null handling and throw IAE with informative messages where 
not allowed nulls are provided. We can't agree to document null handling 
throughout, so lets just agree to leave the more robust bits alone.  
Propagating runtime exceptions with no warning is a bad practice, IMO, but I 
understand that other developers do not want to add null checking everywhere 
and I am not going to insist on it.   A null array, an empty array, a bad set 
of indices are all the same in most places in the stats package - all violate 
the fully specified API contract and lead to informative IAEs.  The NAE is 
needless, but harmless.  If we can't agree to drop it but replace with MathIAE, 
then lets leave as is.
                
> Deprecate "NullArgumentException"
> ---------------------------------
>
>                 Key: MATH-856
>                 URL: https://issues.apache.org/jira/browse/MATH-856
>             Project: Commons Math
>          Issue Type: Task
>    Affects Versions: 3.0
>            Reporter: Gilles
>            Priority: Trivial
>             Fix For: 3.1, 4.0
>
>
> [Discussions|http://markmail.org/message/cl2e6c4pqbluo63e] on the "dev" ML 
> concluded that "NullArgumentException" was more of a burden to maintain than 
> it brings benefits.
> It will be deprecated in 3.1 and removed in 4.0.
> Checks for "null" in CM code will either be maintained or be removed.
> Whenever checks for "null" are performed, the exception to be thrown is the 
> standard "NullPointerException" (instantiated with the no-arg constructor).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to