diff options
author | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2013-10-24 09:52:40 +0300 |
---|---|---|
committer | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2013-10-24 09:52:40 +0300 |
commit | 86d698315608c372868bb55f6d2c609600ac8e41 (patch) | |
tree | 5f82a7e8fcdae868f074a776e7e3e50750f06980 /generator | |
parent | 0848255d4a4b7fa032e962592b15c57b30cd8483 (diff) |
Same fix for EncodedSize.__mul__
Diffstat (limited to 'generator')
-rwxr-xr-x | generator/nanopb_generator.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/generator/nanopb_generator.py b/generator/nanopb_generator.py index aa2c1b38..89647c2c 100755 --- a/generator/nanopb_generator.py +++ b/generator/nanopb_generator.py @@ -115,7 +115,7 @@ class EncodedSize: raise ValueError("Cannot add size: " + repr(other)) def __mul__(self, other): - if isinstance(other, int): + if isinstance(other, (int, long)): return EncodedSize(self.value * other, [str(other) + '*' + s for s in self.symbols]) else: raise ValueError("Cannot multiply size: " + repr(other)) |