Gave up on renameAway() as it was, but implemented getFreeVars() and renameVarsToVars() to fill the same role.