Non-static compile improvements (with corresponding tests).