Show More
@@ -1063,7 +1063,7 b' class revlog(object):' | |||
|
1063 | 1063 | checkrev(r) |
|
1064 | 1064 | # and we're sure ancestors aren't filtered as well |
|
1065 | 1065 | |
|
1066 | if rustancestor is not None: | |
|
1066 | if rustancestor is not None and self.index.rust_ext_compat: | |
|
1067 | 1067 | lazyancestors = rustancestor.LazyAncestors |
|
1068 | 1068 | arg = self.index |
|
1069 | 1069 | else: |
@@ -1150,7 +1150,7 b' class revlog(object):' | |||
|
1150 | 1150 | if common is None: |
|
1151 | 1151 | common = [nullrev] |
|
1152 | 1152 | |
|
1153 | if rustancestor is not None: | |
|
1153 | if rustancestor is not None and self.index.rust_ext_compat: | |
|
1154 | 1154 | return rustancestor.MissingAncestors(self.index, common) |
|
1155 | 1155 | return ancestor.incrementalmissingancestors(self.parentrevs, common) |
|
1156 | 1156 | |
@@ -1370,7 +1370,7 b' class revlog(object):' | |||
|
1370 | 1370 | return self.index.headrevs() |
|
1371 | 1371 | except AttributeError: |
|
1372 | 1372 | return self._headrevs() |
|
1373 | if rustdagop is not None: | |
|
1373 | if rustdagop is not None and self.index.rust_ext_compat: | |
|
1374 | 1374 | return rustdagop.headrevs(self.index, revs) |
|
1375 | 1375 | return dagop.headrevs(revs, self._uncheckedparentrevs) |
|
1376 | 1376 |
@@ -274,6 +274,8 b' class partialdiscovery(object):' | |||
|
274 | 274 | return sample |
|
275 | 275 | |
|
276 | 276 | |
|
277 | pure_partialdiscovery = partialdiscovery | |
|
278 | ||
|
277 | 279 | partialdiscovery = policy.importrust( |
|
278 | 280 | 'discovery', member='PartialDiscovery', default=partialdiscovery |
|
279 | 281 | ) |
@@ -434,9 +436,11 b' def findcommonheads(' | |||
|
434 | 436 | hard_limit_sample = not (dynamic_sample or remote.limitedarguments) |
|
435 | 437 | |
|
436 | 438 | randomize = ui.configbool(b'devel', b'discovery.randomize') |
|
437 | disco = partialdiscovery( | |
|
438 | local, ownheads, hard_limit_sample, randomize=randomize | |
|
439 | ) | |
|
439 | if cl.index.rust_ext_compat: | |
|
440 | pd = partialdiscovery | |
|
441 | else: | |
|
442 | pd = pure_partialdiscovery | |
|
443 | disco = pd(local, ownheads, hard_limit_sample, randomize=randomize) | |
|
440 | 444 | if initial_head_exchange: |
|
441 | 445 | # treat remote heads (and maybe own heads) as a first implicit sample |
|
442 | 446 | # response |
General Comments 0
You need to be logged in to leave comments.
Login now