Ensure `checkJava` callback is executed if Java is not installed.
Hoist local `defaultModes` as `DEFAULT_MODES`.
Tweak how comment is captured when augmenting placeholder assignments.