gh-153568: Don't materialize parser token text that is never read (#1… · python/cpython@e5fbabb · GitHub
Skip to content

Commit e5fbabb

Browse files
pablogsalmaurycy
andauthored
gh-153568: Don't materialize parser token text that is never read (#153576)
* gh-153568: Don't materialize parser token text that is never read Only tokens whose text is actually consumed get a bytes object; operators and structural tokens no longer allocate one. * Update Parser/pegen.c Co-authored-by: Maurycy Pawłowski-Wieroński <maurycy@maurycy.com> * gh-153568: Preserve keyword token text --------- Co-authored-by: Maurycy Pawłowski-Wieroński <maurycy@maurycy.com>
1 parent c215919 commit e5fbabb

2 files changed

Lines changed: 39 additions & 6 deletions

File tree

Lines changed: 2 additions & 0 deletions

Parser/pegen.c

Lines changed: 37 additions & 6 deletions

0 commit comments

Comments
 (0)