comparison mercurial/patch.py @ 41513:a5d8824483ba

diff: drop duplicate filter of copies by destination I'm pretty sure we don't need to filter copies by destination, at least since the previous patch. Differential Revision: https://phab.mercurial-scm.org/D5790
author Martin von Zweigbergk <martinvonz@google.com>
date Thu, 31 Jan 2019 16:51:52 -0800
parents a02c8b605d31
children bd3f03d8cc9f
comparison
equal deleted inserted replaced
41512:a02c8b605d31 41513:a5d8824483ba
2341 copy = {} 2341 copy = {}
2342 if opts.git or opts.upgrade: 2342 if opts.git or opts.upgrade:
2343 copy = copies.pathcopies(ctx1, ctx2, match=match) 2343 copy = copies.pathcopies(ctx1, ctx2, match=match)
2344 2344
2345 if relroot: 2345 if relroot:
2346 # filter out copies where either side isn't inside the relative root 2346 # filter out copies where source side isn't inside the relative root
2347 copy = dict(((dst, src) for (dst, src) in copy.iteritems() 2347 # (copies.pathcopies() already filtered out the destination)
2348 if dst.startswith(relroot) 2348 copy = {dst: src for dst, src in copy.iteritems()
2349 and src.startswith(relroot))) 2349 if src.startswith(relroot)}
2350 2350
2351 modifiedset = set(modified) 2351 modifiedset = set(modified)
2352 addedset = set(added) 2352 addedset = set(added)
2353 removedset = set(removed) 2353 removedset = set(removed)
2354 for f in modified: 2354 for f in modified: