mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
GH-107263: Increase C stack limit for most functions, except _PyEval_EvalFrameDefault()
(GH-107535)
* Set C recursion limit to 1500, set cost of eval loop to 2 frames, and compiler mutliply to 2.
This commit is contained in:
parent
0bd784b355
commit
fa45958450
21 changed files with 57 additions and 45 deletions
|
@ -6,7 +6,7 @@ import sys
|
|||
from functools import cmp_to_key
|
||||
|
||||
from test import seq_tests
|
||||
from test.support import ALWAYS_EQ, NEVER_EQ
|
||||
from test.support import ALWAYS_EQ, NEVER_EQ, C_RECURSION_LIMIT
|
||||
|
||||
|
||||
class CommonTest(seq_tests.CommonTest):
|
||||
|
@ -61,7 +61,7 @@ class CommonTest(seq_tests.CommonTest):
|
|||
|
||||
def test_repr_deep(self):
|
||||
a = self.type2test([])
|
||||
for i in range(sys.getrecursionlimit() + 100):
|
||||
for i in range(C_RECURSION_LIMIT + 1):
|
||||
a = self.type2test([a])
|
||||
self.assertRaises(RecursionError, repr, a)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue