equal
deleted
inserted
replaced
141 return (data[pos:zeropos], hashval, flags) |
141 return (data[pos:zeropos], hashval, flags) |
142 |
142 |
143 __next__ = next |
143 __next__ = next |
144 |
144 |
145 |
145 |
146 def unhexlify(data, extra, pos, length): |
146 def unhexlify(data: bytes, extra: int, pos, length: int): |
147 s = bin(data[pos : pos + length]) |
147 s = bin(data[pos : pos + length]) |
148 if extra: |
148 if extra: |
149 s += chr(extra & 0xFF) |
149 s += bytes([extra & 0xFF]) |
150 return s |
150 return s |
151 |
151 |
152 |
152 |
153 def _cmp(a, b): |
153 def _cmp(a, b): |
154 return (a > b) - (a < b) |
154 return (a > b) - (a < b) |