Mercurial > public > mercurial-scm > hg
comparison mercurial/win32.py @ 18175:fd3f8b87b682
win32: clean up use of two-argument raise
This makes any attempt to port to Python 3 harder, and the new syntax
is supported in 2.4 already.
author | Augie Fackler <raf@durin42.com> |
---|---|
date | Tue, 01 Jan 2013 12:50:23 -0600 |
parents | 72803c8edaa4 |
children | 2f6418d8a4c9 |
comparison
equal
deleted
inserted
replaced
18174:56ef99fbd6f2 | 18175:fd3f8b87b682 |
---|---|
368 break | 368 break |
369 except OSError, e: | 369 except OSError, e: |
370 if e.errno != errno.EEXIST: | 370 if e.errno != errno.EEXIST: |
371 raise | 371 raise |
372 else: | 372 else: |
373 raise IOError, (errno.EEXIST, "No usable temporary filename found") | 373 raise IOError(errno.EEXIST, "No usable temporary filename found") |
374 | 374 |
375 try: | 375 try: |
376 os.unlink(temp) | 376 os.unlink(temp) |
377 except OSError: | 377 except OSError: |
378 # The unlink might have failed because the READONLY attribute may heave | 378 # The unlink might have failed because the READONLY attribute may heave |