null-literal argument: testdata warnings fixed

This commit is contained in:
Dmitry Batkovich
2016-08-23 17:11:43 +03:00
parent 0b95b19068
commit c42625863d
2 changed files with 2 additions and 2 deletions
@@ -17,7 +17,7 @@ class Test {
}
@NotNull
private static <T> T notNull(@Nullable T <warning descr="Method fails when parameter 'value' is 'null'">value</warning>) {
private static <T> T notNull(@Nullable T value) {
if (value == null) {
throw new RuntimeException("null");
@@ -1,7 +1,7 @@
import java.util.Objects;
class Test {
private static void testMethod(Object <warning descr="Method fails when parameter 'o' is 'null'">o</warning>, Object o2, Object <warning descr="Method fails when parameter 'o3' is 'null'">o3</warning>, Object o4, int i) {
private static void testMethod(Object <warning descr="Method will throw an exception when parameter is null">o</warning>, Object o2, Object <warning descr="Method will throw an exception when parameter is null">o3</warning>, Object o4, int i) {
Objects.requireNonNull(o, "o is not null");
if (o3 != null) {
System.out.println(o3.hashCode());