MCPcopy Index your code
hub / github.com/lutzroeder/netron / _parseName

Method _parseName

source/python.js:1579–1591  ·  view source on GitHub ↗
(required)

Source from the content-addressed store, hash-verified

1577 return elts[0];
1578 }
1579 _parseName(required) {
1580 const token = this._tokenizer.peek();
1581 if (token.type === 'id' && !token.keyword) {
1582 const position = this._position();
1583 this._tokenizer.read();
1584 const node = new ast.Name(token.value);
1585 return this._mark(node, position);
1586 }
1587 if (required) {
1588 throw new python.Error(`Invalid syntax ${this._location()}`);
1589 }
1590 return null;
1591 }
1592 _parseDottedName() {
1593 const list = [];
1594 do {

Callers 4

_parseStatementMethod · 0.80
_parseExpressionMethod · 0.80
_parseDottedNameMethod · 0.80
readMethod · 0.80

Calls 5

_positionMethod · 0.80
_markMethod · 0.80
peekMethod · 0.45
readMethod · 0.45
_locationMethod · 0.45

Tested by

no test coverage detected