class GenericArrayMethodArgument { static class Foo { public void foo(T[] array) {} } public void bar() { Foo foo = new Foo<>(); foo.foo(new String[1]); } }