patch: add close() to abstractbackend
authorMartin von Zweigbergk <martinvonz@google.com>
Fri, 30 Jun 2017 09:07:24 -0700
changeset 33155 b8ae289a7707
parent 33154 4ecc6047d45f
child 33156 5ebf39ae10ed
patch: add close() to abstractbackend patchbackend() seems to call it on an arbitrary backend, so it seems to be part of the API. Since all subclasses do something in their close() methods, I decided to let this one raise an exception rather than just pass.
mercurial/patch.py
--- a/mercurial/patch.py	Mon Jun 26 15:46:24 2017 +0200
+++ b/mercurial/patch.py	Fri Jun 30 09:07:24 2017 -0700
@@ -448,6 +448,9 @@
     def exists(self, fname):
         raise NotImplementedError
 
+    def close(self):
+        raise NotImplementedError
+
 class fsbackend(abstractbackend):
     def __init__(self, ui, basedir):
         super(fsbackend, self).__init__(ui)