mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
bpo-46430: Intern strings in deep-frozen modules (GH-30683)
This commit is contained in:
parent
128ab092ca
commit
c0a5ebeb12
4 changed files with 16 additions and 0 deletions
|
@ -279,6 +279,7 @@ class Printer:
|
|||
self.write(f".co_cellvars = {co_cellvars},")
|
||||
self.write(f".co_freevars = {co_freevars},")
|
||||
self.deallocs.append(f"_PyStaticCode_Dealloc(&{name});")
|
||||
self.patchups.append(f"_PyStaticCode_InternStrings(&{name});")
|
||||
return f"& {name}.ob_base"
|
||||
|
||||
def generate_tuple(self, name: str, t: Tuple[object, ...]) -> str:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue