mercurial/utils/hashutil.py
author Martin von Zweigbergk <martinvonz@google.com>
Tue, 18 Aug 2020 14:26:49 -0700
changeset 45407 cf21cda4281f
parent 44059 7126d8b8e0e6
child 46413 521ac0d7047f
permissions -rw-r--r--
tests: add test showing that merge state is not cleared by amend This is slightly modified version of the test case I provided in issue6304. Differential Revision: https://phab.mercurial-scm.org/D8931

from __future__ import absolute_import

import hashlib

try:
    from ..thirdparty import sha1dc

    sha1 = sha1dc.sha1
except (ImportError, AttributeError):
    sha1 = hashlib.sha1