diff options
| author | Georg Brandl <georg@python.org> | 2008-01-05 19:44:22 +0000 |
|---|---|---|
| committer | Georg Brandl <georg@python.org> | 2008-01-05 19:44:22 +0000 |
| commit | f725b9587ce8fb1f63244e69e59763cef0750658 (patch) | |
| tree | 147e583f659c303a48a6e00e03d4ebc6f3776466 /Doc/reference | |
| parent | 6265833d91b53aec0d710d81ec91cee142b0e204 (diff) | |
| download | cpython-git-f725b9587ce8fb1f63244e69e59763cef0750658.tar.gz | |
Doc patch #1730 from Robin Stocker; minor corrections mostly to os.rst.
Diffstat (limited to 'Doc/reference')
| -rw-r--r-- | Doc/reference/expressions.rst | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/Doc/reference/expressions.rst b/Doc/reference/expressions.rst index ea2bb1a057..21bd750a3c 100644 --- a/Doc/reference/expressions.rst +++ b/Doc/reference/expressions.rst @@ -811,9 +811,9 @@ Unary arithmetic operations .. index:: triple: unary; arithmetic; operation - triple: unary; bit-wise; operation + triple: unary; bitwise; operation -All unary arithmetic (and bit-wise) operations have the same priority: +All unary arithmetic (and bitwise) operations have the same priority: .. productionlist:: u_expr: `power` | "-" `u_expr` | "+" `u_expr` | "~" `u_expr` @@ -830,8 +830,8 @@ The unary ``+`` (plus) operator yields its numeric argument unchanged. .. index:: single: inversion -The unary ``~`` (invert) operator yields the bit-wise inversion of its plain or -long integer argument. The bit-wise inversion of ``x`` is defined as +The unary ``~`` (invert) operator yields the bitwise inversion of its plain or +long integer argument. The bitwise inversion of ``x`` is defined as ``-(x+1)``. It only applies to integral numbers. .. index:: exception: TypeError @@ -944,10 +944,10 @@ Negative shift counts raise a :exc:`ValueError` exception. .. _bitwise: -Binary bit-wise operations -========================== +Binary bitwise operations +========================= -.. index:: triple: binary; bit-wise; operation +.. index:: triple: binary; bitwise; operation Each of the three bitwise operations has a different priority level: @@ -956,20 +956,20 @@ Each of the three bitwise operations has a different priority level: xor_expr: `and_expr` | `xor_expr` "^" `and_expr` or_expr: `xor_expr` | `or_expr` "|" `xor_expr` -.. index:: pair: bit-wise; and +.. index:: pair: bitwise; and The ``&`` operator yields the bitwise AND of its arguments, which must be plain or long integers. The arguments are converted to a common type. .. index:: - pair: bit-wise; xor + pair: bitwise; xor pair: exclusive; or The ``^`` operator yields the bitwise XOR (exclusive OR) of its arguments, which must be plain or long integers. The arguments are converted to a common type. .. index:: - pair: bit-wise; or + pair: bitwise; or pair: inclusive; or The ``|`` operator yields the bitwise (inclusive) OR of its arguments, which |
