Fix Java 6 generic inference