MCPcopy Create free account
hub / github.com/numpy/numpy / get_token

Function get_token

tools/npy_tempita/__init__.py:1039–1048  ·  view source on GitHub ↗
(pos=False)

Source from the content-addressed store, hash-verified

1037 defaults = {}
1038
1039 def get_token(pos=False):
1040 try:
1041 tok_type, tok_string, (srow, scol), (erow, ecol), line = next(
1042 tokens)
1043 except StopIteration:
1044 return tokenize.ENDMARKER, ''
1045 if pos:
1046 return tok_type, tok_string, (srow, scol), (erow, ecol)
1047 else:
1048 return tok_type, tok_string
1049 while 1:
1050 var_arg_type = None
1051 tok_type, tok_string = get_token()

Callers 1

parse_signatureFunction · 0.85

Calls 1

nextFunction · 0.70

Tested by

no test coverage detected