mirror of
https://github.com/python/cpython.git
synced 2025-10-17 12:18:23 +00:00
Issue #14741: Fix missing support for ellipsis in parser module.
This commit is contained in:
parent
11c1dee183
commit
da029fb293
3 changed files with 5 additions and 5 deletions
|
@ -2389,17 +2389,13 @@ validate_atom(node *tree)
|
|||
break;
|
||||
case NAME:
|
||||
case NUMBER:
|
||||
case ELLIPSIS:
|
||||
res = (nch == 1);
|
||||
break;
|
||||
case STRING:
|
||||
for (pos = 1; res && (pos < nch); ++pos)
|
||||
res = validate_ntype(CHILD(tree, pos), STRING);
|
||||
break;
|
||||
case DOT:
|
||||
res = (nch == 3 &&
|
||||
validate_ntype(CHILD(tree, 1), DOT) &&
|
||||
validate_ntype(CHILD(tree, 2), DOT));
|
||||
break;
|
||||
default:
|
||||
res = 0;
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue