diff options
| author | Christian Clauss <cclauss@me.com> | 2023-03-10 07:33:32 +0100 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2023-05-02 16:36:05 +1000 |
| commit | 2a1db770ce8d024b31bd1680e501e8b2a65f6570 (patch) | |
| tree | fcbba2b18067f5d36764cb1d5b340b683f5d5534 /tools/mpy-tool.py | |
| parent | 79e57473b20707ca948920fbce473d64dbd8ce25 (diff) | |
all: Fix cases of Python variable assigned but never used.
This fixes ruff rule F841.
Diffstat (limited to 'tools/mpy-tool.py')
| -rwxr-xr-x | tools/mpy-tool.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/tools/mpy-tool.py b/tools/mpy-tool.py index fe83305d7..7f581d0b1 100755 --- a/tools/mpy-tool.py +++ b/tools/mpy-tool.py @@ -1120,7 +1120,6 @@ class RawCodeNative(RawCode): i_top = len(self.fun_data) i = 0 - qi = 0 while i < i_top: # copy machine code (max 16 bytes) i16 = min(i + 16, i_top) @@ -1276,7 +1275,7 @@ def read_raw_code(reader, parent_name, qstr_table, obj_table, segments): if native_scope_flags & MP_SCOPE_FLAG_VIPERRODATA: rodata_size = reader.read_uint() if native_scope_flags & MP_SCOPE_FLAG_VIPERBSS: - bss_size = reader.read_uint() + reader.read_uint() # bss_size if native_scope_flags & MP_SCOPE_FLAG_VIPERRODATA: reader.read_bytes(rodata_size) if native_scope_flags & MP_SCOPE_FLAG_VIPERRELOC: @@ -1285,10 +1284,10 @@ def read_raw_code(reader, parent_name, qstr_table, obj_table, segments): if op == 0xFF: break if op & 1: - addr = reader.read_uint() + reader.read_uint() # addr op >>= 1 if op <= 5 and op & 1: - n = reader.read_uint() + reader.read_uint() # n else: assert kind == MP_CODE_NATIVE_ASM native_n_pos_args = reader.read_uint() |
