# HG changeset patch # User Pierre-Yves David # Date 1356313799 -3600 # Node ID 8870dc73f4418b0a8f0da471235d57608de84d5f # Parent 62cc0851c70f644f99de03abba11132873189965 branchmap: move validity logic in the object itself In several place, We check if a branchcache is still valid regarding the current state of the repository. This changeset puts this logic in a method of the object that can be reused when necessary. A branch map is considered valid whenever it is up to date or a strict subset of the repository state. The change will help making branchcache aware of filtered revision. The change in keyword is expected. the branch cache is actually invalid after the amend. The previous check did not detected it. [ original upstream message ] diff -r 62cc0851c70f -r 8870dc73f441 tests/test-keyword.t --- a/tests/test-keyword.t Wed Dec 12 15:17:18 2012 -0800 +++ b/tests/test-keyword.t Mon Dec 24 02:49:59 2012 +0100 @@ -507,6 +507,7 @@ $ hg -q commit -d '14 1' -m 'prepare amend' $ hg --debug commit --amend -d '15 1' -m 'amend without changes' | grep keywords + invalidating branch cache (tip differs) overwriting a expanding keywords $ hg -q id 67d8c481a6be