bpo-1635741: Convert _sre types to heap types and establish module state (PEP 384) (GH-23393)

This commit is contained in:
Erlend Egeberg Aasland 2020-11-20 13:36:23 +01:00 committed by GitHub
parent 2db8e35489
commit a6109ef68d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 383 additions and 492 deletions

View file

@ -2197,6 +2197,10 @@ class ImplementationTest(unittest.TestCase):
self.assertEqual(f("ababba"), [0, 0, 1, 2, 0, 1])
self.assertEqual(f("abcabdac"), [0, 0, 0, 1, 2, 0, 1, 0])
def test_signedness(self):
self.assertGreaterEqual(sre_compile.MAXREPEAT, 0)
self.assertGreaterEqual(sre_compile.MAXGROUPS, 0)
class ExternalTests(unittest.TestCase):