Mercurial > public > mercurial-scm > hg-stable
diff mercurial/scmutil.py @ 29341:0d83ad967bf8
cleanup: replace uses of util.(md5|sha1|sha256|sha512) with hashlib.\1
All versions of Python we support or hope to support make the hash
functions available in the same way under the same name, so we may as
well drop the util forwards.
author | Augie Fackler <raf@durin42.com> |
---|---|
date | Fri, 10 Jun 2016 00:12:33 -0400 |
parents | 9368ed12f3c0 |
children | 4e6e280e238f |
line wrap: on
line diff
--- a/mercurial/scmutil.py Fri Jun 10 00:25:07 2016 -0400 +++ b/mercurial/scmutil.py Fri Jun 10 00:12:33 2016 -0400 @@ -10,6 +10,7 @@ import contextlib import errno import glob +import hashlib import os import re import shutil @@ -224,7 +225,7 @@ key = None revs = sorted(r for r in cl.filteredrevs if r <= maxrev) if revs: - s = util.sha1() + s = hashlib.sha1() for rev in revs: s.update('%s;' % rev) key = s.digest()