I'm trying to parse all Verilog defines I have in a specific file in my Verilog code. I.e. scan through definitions like the following:
`define A 3
`define B 5
`define C (A+B)
And translate it to a python dictionary: {'A':3, 'B':5, 'C':8}
Does Cocotb have functionality for this, or do I need to define my own parser?
I skimmed through the documentation and didn't find something supporting it, but may have missed something.