+1 for with. Did you check whether it is available in any previous python versions we care about?