aboutsummaryrefslogtreecommitdiff
path: root/chisel_utils.py
diff options
context:
space:
mode:
authorAndrew Waterman <andrew@sifive.com>2024-10-31 12:52:33 -0700
committerGitHub <noreply@github.com>2024-10-31 12:52:33 -0700
commit699eb166dfbe3d96951d20f531b0ebbce49c0459 (patch)
treed14a4037534bcba684a97c8d8987415fcc0fb0d3 /chisel_utils.py
parentf73c2a41c868c4f90446396b116f29078fcf3f17 (diff)
parent284a5fa0f79ae5415d6ab2009193d3bead64d2aa (diff)
downloadriscv-opcodes-699eb166dfbe3d96951d20f531b0ebbce49c0459.zip
riscv-opcodes-699eb166dfbe3d96951d20f531b0ebbce49c0459.tar.gz
riscv-opcodes-699eb166dfbe3d96951d20f531b0ebbce49c0459.tar.bz2
Merge pull request #293 from Timmmm/user/timh/types
Add static type hints
Diffstat (limited to 'chisel_utils.py')
-rw-r--r--chisel_utils.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/chisel_utils.py b/chisel_utils.py
index 0943584..9916b76 100644
--- a/chisel_utils.py
+++ b/chisel_utils.py
@@ -10,7 +10,7 @@ pp = pprint.PrettyPrinter(indent=2)
logging.basicConfig(level=logging.INFO, format="%(levelname)s:: %(message)s")
-def make_chisel(instr_dict, spinal_hdl=False):
+def make_chisel(instr_dict: InstrDict, spinal_hdl: bool = False):
chisel_names = ""
cause_names_str = ""
@@ -31,7 +31,7 @@ def make_chisel(instr_dict, spinal_hdl=False):
elif "rv_" in e:
e_format = e.replace("rv_", "").upper()
else:
- e_format = e.upper
+ e_format = e.upper()
chisel_names += f' val {e_format+"Type"} = Map(\n'
for instr in e_instrs:
tmp_instr_name = '"' + instr.upper().replace(".", "_") + '"'