MCPcopy
hub / github.com/psf/black / printtoken

Function printtoken

src/blib2to3/pgen2/tokenize.py:262–267  ·  view source on GitHub ↗
(
    type: int, token: str, srow_col: Coord, erow_col: Coord, line: str
)

Source from the content-addressed store, hash-verified

260
261
262def printtoken(
263 type: int, token: str, srow_col: Coord, erow_col: Coord, line: str
264) -> None: # for testing
265 srow, scol = srow_col
266 erow, ecol = erow_col
267 print(f"{srow},{scol}-{erow},{ecol}:\t{tok_name[type]}\t{token!r}")
268
269
270if __name__ == "__main__": # testing

Callers 1

tokenize.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected