Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/pvec.py @ 24339:bcc319d936a3
pvec: replace 'ctx._repo' with 'ctx.repo()'
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Thu, 12 Mar 2015 23:18:20 -0400 |
parents | 5093d2a87ff6 |
children | 983e93d88193 |
comparison
equal
deleted
inserted
replaced
24338:ca1365078c86 | 24339:bcc319d936a3 |
---|---|
140 bit = (hash(node) & 0xffffffff) % _vecbits | 140 bit = (hash(node) & 0xffffffff) % _vecbits |
141 return v ^ (1<<bit) | 141 return v ^ (1<<bit) |
142 | 142 |
143 def ctxpvec(ctx): | 143 def ctxpvec(ctx): |
144 '''construct a pvec for ctx while filling in the cache''' | 144 '''construct a pvec for ctx while filling in the cache''' |
145 r = ctx._repo | 145 r = ctx.repo() |
146 if not util.safehasattr(r, "_pveccache"): | 146 if not util.safehasattr(r, "_pveccache"): |
147 r._pveccache = {} | 147 r._pveccache = {} |
148 pvc = r._pveccache | 148 pvc = r._pveccache |
149 if ctx.rev() not in pvc: | 149 if ctx.rev() not in pvc: |
150 cl = r.changelog | 150 cl = r.changelog |