From 02079206d4cd50b98043315c4fde7111f48a8ae5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Sl=C3=A1me=C4=8Dka?= Date: Mon, 20 Feb 2023 15:23:27 +0000 Subject: [PATCH] Use correct variable name when avoiding name clashes of imports --- capnpy/compiler/module.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/capnpy/compiler/module.py b/capnpy/compiler/module.py index bf5d4c7e..abc3dec4 100644 --- a/capnpy/compiler/module.py +++ b/capnpy/compiler/module.py @@ -130,7 +130,7 @@ def register_import(self, fname): name = '_%s_capnp' % name if name in self.importnames.values(): # avoid name clashes - name = '%s_%s' % (name, len(self.filenames)) + name = '%s_%s' % (name, len(self.importnames)) self.importnames[fname] = name return name