Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/utils/storageutil.py @ 52676:f066fc0bdc7a
pyupgrade: use set literals where possible
This was rewritten by the `set_literals` fixer in `pyupgrade`. I thought there
was a past change around using set literals, but I can't find it now.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Mon, 06 Jan 2025 01:33:08 -0500 |
parents | f4733654f144 |
children |
comparison
equal
deleted
inserted
replaced
52675:b95b12cb31e2 | 52676:f066fc0bdc7a |
---|---|
397 | 397 |
398 # Sets of revs available to delta against. | 398 # Sets of revs available to delta against. |
399 emitted = set() | 399 emitted = set() |
400 available = set() | 400 available = set() |
401 if assumehaveparentrevisions: | 401 if assumehaveparentrevisions: |
402 common_heads = set(p for r in revs for p in parents(r)) | 402 common_heads = {p for r in revs for p in parents(r)} |
403 common_heads.difference_update(revs) | 403 common_heads.difference_update(revs) |
404 available = store.ancestors(common_heads, inclusive=True) | 404 available = store.ancestors(common_heads, inclusive=True) |
405 | 405 |
406 def is_usable_base(rev): | 406 def is_usable_base(rev): |
407 """Is a delta against this revision usable over the wire""" | 407 """Is a delta against this revision usable over the wire""" |