MCPcopy
hub / github.com/lutzroeder/netron / _parseTypeArguments

Method _parseTypeArguments

source/python.js:1609–1624  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1607 return null;
1608 }
1609 _parseTypeArguments() {
1610 const list = [];
1611 this._tokenizer.expect('[');
1612 while (!this._tokenizer.accept(']')) {
1613 const type = this._parseType();
1614 if (type === null) {
1615 throw new python.Error(`Expected type ${this._location()}`);
1616 }
1617 list.push(type);
1618 if (!this._tokenizer.accept(',')) {
1619 this._tokenizer.expect(']');
1620 break;
1621 }
1622 }
1623 return list;
1624 }
1625 _parseType() {
1626 const target = this._parseExpression(-1, ['[', '=']);
1627 if (target) {

Callers

nothing calls this directly

Calls 5

expectMethod · 0.45
acceptMethod · 0.45
_parseTypeMethod · 0.45
_locationMethod · 0.45
pushMethod · 0.45

Tested by

no test coverage detected