FIx code and comments for Java 8
Merge remote-tracking branch 'origin/master'