The code now compiles on JDK 1.8