I'm currently learning Java generics, and while going through the Oracle's tutorial in Wildcard capture and helper methods it suddenly hit me: what is the benefit of:
void someMethod(List<?> list) { // .. }
over:
<T> void someMethod(List<T> list) { // .. }
?
The reason I ask is that the link provided above presents a certain compilation error that occurs while using the first form (using wildcards), which is solved by using a helper method of the second form. So the question arises - why use the first form in the first place?