New GitHub issue #101277 from erlend-aasland:<br>
<hr>
<pre>
# Feature or enhancement
Following https://github.com/ericsnowcurrently/multi-core-python/wiki/0-The-Plan we need to convert the `itertools` extension module to use module state.
There are multiple static global type objects:
https://github.com/python/cpython/blob/e244401ce508ad391295beb636e499fcc6797a2a/Tools/c-analyzer/cpython/globals-to-fix.tsv#L338-L359
We need to convert these to heap types, add module state, and implement multi-phase init.
See also PEP-687.
I've got an old PR (#24065) that I'm planning on resurrecting. I'll re-submit it as multiple PRs; this is going to be a large change.
For this particular module, it could make sense to add a module state pointer to each type context, for easy and cheap state access.
</pre>
<hr>
<a href="https://github.com/python/cpython/issues/101277">View on GitHub</a>
<p>Labels: type-feature</p>
<p>Assignee: erlend-aasland</p>