Skip to content

Commit f64d749

Browse files
committed
ruff fixes
1 parent 5ffa1f3 commit f64d749

3 files changed

Lines changed: 3 additions & 5 deletions

File tree

pypcode/processors/RISCV/scripts/binutil.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@
2222
Data was copied from various files in binutils, a lot of it unused.
2323
"""
2424

25-
import sys
26-
import re
2725

2826
MATCH_SLLI_RV32=0x1013
2927
MASK_SLLI_RV32=0xfe00707f
@@ -2779,7 +2777,7 @@ def find_gaps(op):
27792777
pattern = 0x0
27802778
for x in op.bitpattern:
27812779
x = x.split('=')[0]
2782-
if not x in gap.keys():
2780+
if x not in gap.keys():
27832781
print("GAP: %r" % x)
27842782
exit(1)
27852783
x = gap[x]

scripts/benchmark.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import time
1818
from dataclasses import dataclass
1919

20-
from typing import cast, Any, Dict, List, Tuple
20+
from typing import cast, Any
2121
from collections.abc import Callable, Iterable
2222

2323
logging.basicConfig(level=logging.INFO)

tests/test_pypcode.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import logging
66
from unittest import main, TestCase
77
from unittest.mock import create_autospec
8-
from typing import cast, List
8+
from typing import cast
99

1010
from pypcode import (
1111
AddrSpace,

0 commit comments

Comments
 (0)