summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1998-04-09 17:54:26 (GMT)
committerGuido van Rossum <guido@python.org>1998-04-09 17:54:26 (GMT)
commit99c185e787de428ad09265401da9f8eba8c2ad99 (patch)
tree1bb605d6d94630da163cf1cedde9416b89fd09d7 /Modules
parentc3d3f9692d2ac91d064681621240121a9407501d (diff)
downloadcpython-99c185e787de428ad09265401da9f8eba8c2ad99.zip
cpython-99c185e787de428ad09265401da9f8eba8c2ad99.tar.gz
cpython-99c185e787de428ad09265401da9f8eba8c2ad99.tar.bz2
Add not_ and __not__.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/operator.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/Modules/operator.c b/Modules/operator.c
index 14a7aaf..4e9111d 100644
--- a/Modules/operator.c
+++ b/Modules/operator.c
@@ -124,6 +124,7 @@ spam1(op_abs , PyNumber_Absolute)
spam1(op_inv , PyNumber_Invert)
spam2(op_lshift , PyNumber_Lshift)
spam2(op_rshift , PyNumber_Rshift)
+spami(op_not_ , PyObject_Not)
spam2(op_and_ , PyNumber_And)
spam2(op_xor , PyNumber_Xor)
spam2(op_or_ , PyNumber_Or)
@@ -226,6 +227,7 @@ spam2(abs,__abs__, "abs(o) -- Return the absolute value of o.")
spam2(inv,__inv__, "inv(o) -- Return the inverse of o.")
spam2(lshift,__lshift__, "lshift(a, b) -- Return a shifted left by b.")
spam2(rshift,__rshift__, "rshift(a, b) -- Return a shifted right by b.")
+spam2(not_,__not__, "not_(o) -- Return 0 if o is true, and 1 otherwise.")
spam2(and_,__and__, "and_(a, b) -- Return the bitwise and of a and b.")
spam2(xor,__xor__, "xor(a, b) -- Return the bitwise exclusive-or of a and b.")
spam2(or_,__or__, "or_(a, b) -- Return the bitwise or of a and b.")