Merged #214 proposed fix into isJava40Compliant()