MCPcopy Index your code
hub / github.com/python/cpython / _fill_logical

Method _fill_logical

Lib/_pydecimal.py:3332–3343  ·  view source on GitHub ↗
(self, context, opa, opb)

Source from the content-addressed store, hash-verified

3330 return True
3331
3332 def _fill_logical(self, context, opa, opb):
3333 dif = context.prec - len(opa)
3334 if dif > 0:
3335 opa = '0'*dif + opa
3336 elif dif < 0:
3337 opa = opa[-context.prec:]
3338 dif = context.prec - len(opb)
3339 if dif > 0:
3340 opb = '0'*dif + opb
3341 elif dif < 0:
3342 opb = opb[-context.prec:]
3343 return opa, opb
3344
3345 def logical_and(self, other, context=None):
3346 """Applies an 'and' operation between self and other&#x27;s digits.

Callers 3

logical_andMethod · 0.95
logical_orMethod · 0.95
logical_xorMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected