# HG changeset patch # User Sean Farley # Date 2013-08-15 18:11:51 # Node ID f0f8380ec516e69dc129ffe92cb48a6d6ff151d9 # Parent 8f48f5969b475a3140ed9cc78513065cba2e533d commitablefilectx: add a class that will be used for mutable file contexts Just like commitablectx, this will serve as a common place for code that will be shared between workingfilectx and memfilectx. diff --git a/mercurial/context.py b/mercurial/context.py --- a/mercurial/context.py +++ b/mercurial/context.py @@ -1188,7 +1188,13 @@ class workingctx(commitablectx): finally: wlock.release() -class workingfilectx(basefilectx): +class commitablefilectx(basefilectx): + """A commitablefilectx provides common functionality for a file context that + wants the ability to commit, e.g. workingfilectx or memfilectx.""" + def __init__(self, repo, path, filelog=None, ctx=None): + pass + +class workingfilectx(commitablefilectx): """A workingfilectx object makes access to data related to a particular file in the working directory convenient.""" def __init__(self, repo, path, filelog=None, workingctx=None):