Mercurial > public > mercurial-scm > hg
comparison mercurial/manifest.py @ 52481:22f97aa5e8b2
manifest: subclass the new `imanifestrevisionwritable` Protocol class
This is the same transformation as 3a90a6fd710d did for dirstate, but the
CamelCase naming was already cleaned up here. See 4ef6dbc27a99 for the benefits
of explicit subclassing.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Tue, 22 Oct 2024 22:44:32 -0400 |
parents | d37d8dfe65bd |
children | d371efa7c358 |
comparison
equal
deleted
inserted
replaced
52480:01818a59f463 | 52481:22f97aa5e8b2 |
---|---|
2348 | 2348 |
2349 def find(self, key: bytes) -> Tuple[bytes, bytes]: | 2349 def find(self, key: bytes) -> Tuple[bytes, bytes]: |
2350 return self.read().find(key) | 2350 return self.read().find(key) |
2351 | 2351 |
2352 | 2352 |
2353 class memtreemanifestctx: # (repository.imanifestrevisionwritable) | 2353 class memtreemanifestctx(repository.imanifestrevisionwritable): |
2354 _treemanifest: treemanifest | 2354 _treemanifest: treemanifest |
2355 | 2355 |
2356 def __init__(self, manifestlog, dir=b''): | 2356 def __init__(self, manifestlog, dir=b''): |
2357 self._manifestlog = manifestlog | 2357 self._manifestlog = manifestlog |
2358 self._dir = dir | 2358 self._dir = dir |