Main.java:13: error: incompatible types: Class<CAP#1> cannot be converted to Class<? extends T>
return object.getClass();
^
where T is a type-variable:
T extends Object declared in method <T>getClass(T)
where CAP#1 is a fresh type-variable:
CAP#1 extends Object from capture of ? extends Object
1 error