Skip to content

Commit

Permalink
pythonGH-111807: Lower the parser stack depth under WASI debug builds
Browse files Browse the repository at this point in the history
  • Loading branch information
brettcannon committed Nov 18, 2023
1 parent 43b1c33 commit cd321ff
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Lower the max parser stack depth to 1000 under WASI debug builds.
6 changes: 5 additions & 1 deletion Parser/parser.c

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 5 additions & 1 deletion Tools/peg_generator/pegen/c_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,11 @@
#endif
#ifdef __wasi__
# define MAXSTACK 4000
# ifdef Py_DEBUG
# define MAXSTACK 1000
# else
# define MAXSTACK 4000
# endif
#else
# define MAXSTACK 6000
#endif
Expand Down

0 comments on commit cd321ff

Please sign in to comment.