Restoring Java 6 compatibility