Commit e8643c46 authored by Thomas Wouters's avatar Thomas Wouters

Fix some strange indentation and grammar that have been bugging me for

weeks.
parent cc22fbe3
...@@ -1249,12 +1249,11 @@ com_subscriptlist(struct compiling *c, node *n, int assigning) ...@@ -1249,12 +1249,11 @@ com_subscriptlist(struct compiling *c, node *n, int assigning)
/* Check to make backward compatible slice behavior for '[i:j]' */ /* Check to make backward compatible slice behavior for '[i:j]' */
if (NCH(n) == 1) { if (NCH(n) == 1) {
node *sub = CHILD(n, 0); /* subscript */ node *sub = CHILD(n, 0); /* subscript */
/* Make it is a simple slice. /* 'Basic' slice, should have exactly one colon. */
Should have exactly one colon. */ if ((TYPE(CHILD(sub, 0)) == COLON
if ((TYPE(CHILD(sub, 0)) == COLON || (NCH(sub) > 1 && TYPE(CHILD(sub, 1)) == COLON))
|| (NCH(sub) > 1 && TYPE(CHILD(sub, 1)) == COLON)) && (TYPE(CHILD(sub,NCH(sub)-1)) != sliceop))
&& (TYPE(CHILD(sub,NCH(sub)-1)) != sliceop)) {
{
if (assigning == OP_APPLY) if (assigning == OP_APPLY)
op = SLICE; op = SLICE;
else else
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment