view mercurial/utils/hashutil.py @ 50032:06619266679d

dirstate: use `dirstate.change_files` to scope the change in `forget` This is the way.
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Tue, 13 Dec 2022 16:27:57 +0100
parents 6000f5b25c9b
children f4733654f144
line wrap: on
line source

import hashlib

try:
    from ..thirdparty import sha1dc  # pytype: disable=import-error

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