Skip to content

Commit 3b5f518

Browse files
authored
Merge branch 'main' into enum-docs
2 parents 2d6bdb1 + 33d94ab commit 3b5f518

17 files changed

+372
-145
lines changed

Include/internal/pycore_dict.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,8 +272,7 @@ _PyDict_SendEvent(int watcher_bits,
272272
PyObject *value);
273273

274274
static inline void
275-
_PyDict_NotifyEvent(PyInterpreterState *interp,
276-
PyDict_WatchEvent event,
275+
_PyDict_NotifyEvent(PyDict_WatchEvent event,
277276
PyDictObject *mp,
278277
PyObject *key,
279278
PyObject *value)

Include/internal/pycore_opcode_metadata.h

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Include/internal/pycore_uop_ids.h

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Include/internal/pycore_uop_metadata.h

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Lib/test/test_capi/test_opt.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2988,6 +2988,24 @@ class Obj:
29882988
for _ in range(TIER2_THRESHOLD+1):
29892989
obj.attr = EvilAttr(obj.__dict__)
29902990

2991+
def test_binary_subscr_list_int(self):
2992+
def testfunc(n):
2993+
l = [1]
2994+
x = 0
2995+
for _ in range(n):
2996+
y = l[0]
2997+
x += y
2998+
return x
2999+
3000+
res, ex = self._run_with_optimizer(testfunc, TIER2_THRESHOLD)
3001+
self.assertEqual(res, TIER2_THRESHOLD)
3002+
self.assertIsNotNone(ex)
3003+
uops = get_opnames(ex)
3004+
3005+
self.assertIn("_BINARY_OP_SUBSCR_LIST_INT", uops)
3006+
self.assertNotIn("_POP_TOP", uops)
3007+
self.assertNotIn("_POP_TOP_INT", uops)
3008+
self.assertIn("_POP_TOP_NOP", uops)
29913009

29923010
def global_identity(x):
29933011
return x

Lib/test/test_unicodedata.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -759,7 +759,7 @@ def test_normalization(self):
759759

760760
@requires_resource('cpu')
761761
def test_normalization_3_2_0(self):
762-
testdatafile = findfile('NormalizationTest-3.2.0.txt', 'data')
762+
testdatafile = findfile('NormalizationTest-3.2.0.txt')
763763
with open(testdatafile, encoding='utf-8') as testdata:
764764
self.run_normalization_tests(testdata, unicodedata.ucd_3_2_0)
765765

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Make concurrent iteration over the same range iterator thread-safe in the
2+
free threading build.

Objects/clinic/rangeobject.c.h

Lines changed: 150 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)