@@ -5237,13 +5237,13 @@ _decimal.Decimal.logical_invert = _decimal.Decimal.exp
52375237
52385238Invert all its digits.
52395239
5240- The self should have zero sign and exponent, and digits either 0 or 1 .
5240+ The self must be logical number .
52415241[clinic start generated code]*/
52425242
52435243static PyObject *
52445244_decimal_Decimal_logical_invert_impl (PyObject * self , PyTypeObject * cls ,
52455245 PyObject * context )
5246- /*[clinic end generated code: output=c626ed4b104a97b7 input=fb9eb6253e7639e1 ]*/
5246+ /*[clinic end generated code: output=c626ed4b104a97b7 input=7158d5b525417955 ]*/
52475247Dec_UnaryFuncVA (mpd_qinvert )
52485248
52495249/*[clinic input]
@@ -5475,44 +5475,41 @@ _decimal.Decimal.logical_and = _decimal.Decimal.compare
54755475
54765476Applies an 'and' operation between self and other's digits.
54775477
5478- Both self and other should have zero sign and exponent,
5479- and digits either 0 or 1.
5478+ Both self and other must be logical numbers.
54805479[clinic start generated code]*/
54815480
54825481static PyObject *
54835482_decimal_Decimal_logical_and_impl (PyObject * self , PyTypeObject * cls ,
54845483 PyObject * other , PyObject * context )
5485- /*[clinic end generated code: output=9a4cbb74c180b0bb input=f8857b9b57be75f3 ]*/
5484+ /*[clinic end generated code: output=9a4cbb74c180b0bb input=f22460f1285782d2 ]*/
54865485Dec_BinaryFuncVA (mpd_qand )
54875486
54885487/*[clinic input]
54895488_decimal.Decimal.logical_or = _decimal.Decimal.compare
54905489
54915490Applies an 'or' operation between self and other's digits.
54925491
5493- Both self and other should have zero sign and exponent,
5494- and digits either 0 or 1.
5492+ Both self and other must be logical numbers.
54955493[clinic start generated code]*/
54965494
54975495static PyObject *
54985496_decimal_Decimal_logical_or_impl (PyObject * self , PyTypeObject * cls ,
54995497 PyObject * other , PyObject * context )
5500- /*[clinic end generated code: output=063c4de18dc41ecb input=4043d61390b2a07d ]*/
5498+ /*[clinic end generated code: output=063c4de18dc41ecb input=b5afa1e1fdebdfce ]*/
55015499Dec_BinaryFuncVA (mpd_qor )
55025500
55035501/*[clinic input]
55045502_decimal.Decimal.logical_xor = _decimal.Decimal.compare
55055503
55065504Applies an 'xor' operation between self and other's digits.
55075505
5508- Both self and other should have zero sign and exponent,
5509- and digits either 0 or 1.
5506+ Both self and other must be logical numbers.
55105507[clinic start generated code]*/
55115508
55125509static PyObject *
55135510_decimal_Decimal_logical_xor_impl (PyObject * self , PyTypeObject * cls ,
55145511 PyObject * other , PyObject * context )
5515- /*[clinic end generated code: output=829b09cb49926ad7 input=faea7766e521bdde ]*/
5512+ /*[clinic end generated code: output=829b09cb49926ad7 input=84d722ada08a2da7 ]*/
55165513Dec_BinaryFuncVA (mpd_qxor )
55175514
55185515/*[clinic input]
@@ -7112,8 +7109,7 @@ _decimal.Context.logical_invert = _decimal.Context.abs
71127109
71137110Invert all the digits in the operand.
71147111
7115- The operand should have zero sign and exponent, and digits
7116- either 0 or 1.
7112+ The operand must be a logical number.
71177113
71187114 >>> ExtendedContext.logical_invert(Decimal('0'))
71197115 Decimal('111111111')
@@ -7130,7 +7126,7 @@ either 0 or 1.
71307126static PyObject *
71317127_decimal_Context_logical_invert_impl (PyObject * context , PyTypeObject * cls ,
71327128 PyObject * x )
7133- /*[clinic end generated code: output=97760277a958e2b0 input=c10bbdfd8d864be6 ]*/
7129+ /*[clinic end generated code: output=97760277a958e2b0 input=8e568f4c745ab596 ]*/
71347130DecCtx_UnaryFunc (mpd_qinvert )
71357131
71367132/*[clinic input]
@@ -7289,8 +7285,7 @@ _decimal.Context.logical_and = _decimal.Context.add
72897285
72907286Applies the logical operation 'and' between each operand's digits.
72917287
7292- Both operands should have zero sign and exponent, and
7293- digits either 0 or 1.
7288+ The operands must be both logical numbers.
72947289
72957290 >>> ExtendedContext.logical_and(Decimal('0'), Decimal('0'))
72967291 Decimal('0')
@@ -7315,16 +7310,15 @@ digits either 0 or 1.
73157310static PyObject *
73167311_decimal_Context_logical_and_impl (PyObject * context , PyTypeObject * cls ,
73177312 PyObject * x , PyObject * y )
7318- /*[clinic end generated code: output=009dfa08ecaa2ac8 input=771aebf6de97e246 ]*/
7313+ /*[clinic end generated code: output=009dfa08ecaa2ac8 input=bcb7d3d6ab7530de ]*/
73197314DecCtx_BinaryFunc (mpd_qand )
73207315
73217316/*[clinic input]
73227317_decimal.Context.logical_or = _decimal.Context.add
73237318
73247319Applies the logical operation 'or' between each operand's digits.
73257320
7326- Both operands should have zero sign and exponent, and digits
7327- either 0 or 1.
7321+ The operands must be both logical numbers.
73287322
73297323 >>> ExtendedContext.logical_or(Decimal('0'), Decimal('0'))
73307324 Decimal('0')
@@ -7349,16 +7343,15 @@ either 0 or 1.
73497343static PyObject *
73507344_decimal_Context_logical_or_impl (PyObject * context , PyTypeObject * cls ,
73517345 PyObject * x , PyObject * y )
7352- /*[clinic end generated code: output=eb38617e8d31bf12 input=380611292d885f9d ]*/
7346+ /*[clinic end generated code: output=eb38617e8d31bf12 input=47b45d296fb90846 ]*/
73537347DecCtx_BinaryFunc (mpd_qor )
73547348
73557349/*[clinic input]
73567350_decimal.Context.logical_xor = _decimal.Context.add
73577351
73587352Applies the logical operation 'xor' between each operand's digits.
73597353
7360- Both operands should have zero sign and exponent, and digits
7361- either 0 or 1.
7354+ The operands must be both logical numbers.
73627355
73637356 >>> ExtendedContext.logical_xor(Decimal('0'), Decimal('0'))
73647357 Decimal('0')
@@ -7383,7 +7376,7 @@ either 0 or 1.
73837376static PyObject *
73847377_decimal_Context_logical_xor_impl (PyObject * context , PyTypeObject * cls ,
73857378 PyObject * x , PyObject * y )
7386- /*[clinic end generated code: output=23cd81fdcd865d5a input=a23b928a8d0f5df0 ]*/
7379+ /*[clinic end generated code: output=23cd81fdcd865d5a input=fcaaf828c1d2d089 ]*/
73877380DecCtx_BinaryFunc (mpd_qxor )
73887381
73897382/*[clinic input]
0 commit comments