mercurial/dirstate.py
changeset 50109 bec7182cc406
parent 50108 f7981f202b7a
child 50114 c175b4857498
--- a/mercurial/dirstate.py	Mon Feb 20 11:54:10 2023 +0100
+++ b/mercurial/dirstate.py	Mon Feb 20 11:57:46 2023 +0100
@@ -551,9 +551,7 @@
         self._invalidated_context = self._changing_level > 0
         self._origpl = None
 
-    # XXX since this make the dirstate dirty, we should enforce that it is done
-    # withing an appropriate change-context that scope the change and ensure it
-    # eventually get written on disk (or rolled back)
+    @requires_changing_any
     def copy(self, source, dest):
         """Mark dest as a copy of source. Unmark dest if source is None."""
         if source == dest: