amend: use `update_file` instead of `drop`
This is the newer, more semantic API.
Differential Revision: https://phab.mercurial-scm.org/D11188
--- a/mercurial/cmdutil.py Mon Jul 19 03:16:40 2021 +0200
+++ b/mercurial/cmdutil.py Mon Jul 19 09:07:08 2021 +0200
@@ -3004,7 +3004,7 @@
# to "removed" in the dirstate.
removedfiles = set(wctx.removed()) & filestoamend
for f in removedfiles:
- dirstate.drop(f)
+ dirstate.update_file(f, p1_tracked=False, wc_tracked=False)
mapping = {old.node(): (newid,)}
obsmetadata = None