Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/python/cpython
/ next_token
Method
next_token
Lib/test/test_free_threading/test_tokenize.py:18–25 ·
view source on GitHub ↗
(it)
Source
from the content-addressed store, hash-verified
16
17
tokens = []
18
def
next_token(it):
19
while
True:
20
try
:
21
r = next(it)
22
tokens.append(tokenize.TokenInfo._make(r))
23
time.sleep(0.03)
24
except
StopIteration:
25
return
26
27
threads = []
28
for
_ in range(5):
Callers
nothing calls this directly
Calls
3
append
Method · 0.45
_make
Method · 0.45
sleep
Method · 0.45
Tested by
no test coverage detected