RFR(XXS): 8156226: DiagnosticCommandImpl::invoke throws NoSuchMethodException even if the method actually exists but parameters are wrong
Daniel Fuchs
daniel.fuchs at oracle.com
Sat Jun 11 08:12:47 UTC 2016
On 11/06/16 01:41, David Holmes wrote:
> Better, but I still wonder what Arrays.toString prints for an empty array?
It prints "[]" - like Collections.emptyList().toString():
System.out.println("null: "
+ Arrays.toString((Object[])null));
System.out.println("new Object[0]: "
+ Arrays.toString(new Object[0]));
System.out.println("Arrays.asList(new Object[0]): "
+ Arrays.asList(new Object[0]));
> null: null
> new Object[0]: []
> Arrays.asList(new Object[0]): []
cheers,
-- daniel
More information about the serviceability-dev
mailing list