summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorBrett Cannon <bcannon@gmail.com>2005-03-03 07:01:48 (GMT)
committerBrett Cannon <bcannon@gmail.com>2005-03-03 07:01:48 (GMT)
commit5dc8ced4a889d36be63f6119e5a055c44dfd9507 (patch)
tree16b67dac8f51595e672c671b636a2a9434acefba /Python
parent6a458e9bc9ed1bb9daf99481585ec7496bc95e0b (diff)
downloadcpython-5dc8ced4a889d36be63f6119e5a055c44dfd9507.zip
cpython-5dc8ced4a889d36be63f6119e5a055c44dfd9507.tar.gz
cpython-5dc8ced4a889d36be63f6119e5a055c44dfd9507.tar.bz2
Silence a gcc warning about putting in parentheses around && expressions mixed
with || expressions. Also clarifies intend of 'if' conditional.
Diffstat (limited to 'Python')
-rw-r--r--Python/compile.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/Python/compile.c b/Python/compile.c
index 71e90f7..16bf291 100644
--- a/Python/compile.c
+++ b/Python/compile.c
@@ -778,13 +778,14 @@ optimize_code(PyObject *code, PyObject* consts, PyObject *names, PyObject *linen
h = i - 3 * j;
if (h >= 0 &&
j <= lastlc &&
- (opcode == BUILD_TUPLE &&
- ISBASICBLOCK(blocks, h, 3*(j+1)) ||
- opcode == BUILD_LIST &&
+ ((opcode == BUILD_TUPLE &&
+ ISBASICBLOCK(blocks, h, 3*(j+1))) ||
+ (opcode == BUILD_LIST &&
codestr[i+3]==COMPARE_OP &&
ISBASICBLOCK(blocks, h, 3*(j+2)) &&
- (GETARG(codestr,i+3)==6 || GETARG(codestr,i+3)==7)) &&
- tuple_of_constants(&codestr[h], j, consts)) {
+ (GETARG(codestr,i+3)==6 ||
+ GETARG(codestr,i+3)==7))) &&
+ tuple_of_constants(&codestr[h], j, consts)) {
assert(codestr[i] == LOAD_CONST);
cumlc = 1;
break;