Fix odd type inference issue on jdk6