From patchwork Mon Aug 18 23:36:51 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [2,of,4] revert: drop more dead code From: Pierre-Yves David X-Patchwork-Id: 5484 Message-Id: To: mercurial-devel@selenic.com Cc: Pierre-Yves David Date: Mon, 18 Aug 2014 16:36:51 -0700 # HG changeset patch # User Pierre-Yves David # Date 1403650543 -3600 # Tue Jun 24 23:55:43 2014 +0100 # Node ID dc71811ffcd0443fbec9bdd21d8be6ce7c30659e # Parent 8fd7b8a721f0fa8b35f02354b643bfc73c6f0524 revert: drop more dead code Now that we detect all clean files we do not needs this clause anymore. diff --git a/mercurial/cmdutil.py b/mercurial/cmdutil.py --- a/mercurial/cmdutil.py +++ b/mercurial/cmdutil.py @@ -2523,15 +2523,10 @@ def revert(ui, repo, ctx, parents, *pats if abs not in repo.dirstate: if exact: ui.warn(_('file not managed: %s\n') % rel) continue - # parent is target, no changes mean no changes - if node == parent: - if exact: - ui.warn(_('no changes needed to %s\n') % rel) - continue if not opts.get('dry_run'): _performrevert(repo, parents, ctx, actions) if targetsubs: