From 6b28cc001ff4613ea86113078b207881ab4126fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= Date: Tue, 2 Aug 2022 23:52:31 +0200 Subject: [PATCH] tests: fix _ast_num in script generator --- tests/scripts/python/unparse.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/scripts/python/unparse.py b/tests/scripts/python/unparse.py index 9fc24ee4a..d9c7516ad 100755 --- a/tests/scripts/python/unparse.py +++ b/tests/scripts/python/unparse.py @@ -277,7 +277,7 @@ class UnparsePython(object): def _ast_num(self, node): """Add an AST Num in output.""" # note: deprecated since Python 3.8, replaced by ast.Constant - self._ast_constant(node) + self.add(repr(node.n)) def _ast_pass(self, node): # pylint: disable=unused-argument """Add an AST Pass in output."""