branchcache: gather newly closed head in a dedicated set
This is part of a series to more clearly split the update in two step. This
will allow us to introduce a fast path during update in a future changeset.
local test passed
addgroupcopy test passed
clone test passed
lowlevelcopy test passed
slicing test passed
issnapshot test passed
findsnapshot test passed