On 26/04/2016 12:49, Sergey Ustimenko wrote:
Hi all!

There is a bug described at https://bugs.openjdk.java.net/browse/JDK-8015594

The problem is that if we are using java.util.Pattern.matcher with NULL
argument,
then the NPE will be thrown. As Stuart Marks has noticed in the comments,
that such
behavior have not been specified
The package description has this

 * <p> Unless otherwise noted, passing a <code>null</code> argument to a
 * method in any class or interface in this package will cause a
 * {@link java.lang.NullPointerException NullPointerException} to be
 * thrown.

and so avoids needing to specifying it on every method.

-Alan

Reply via email to