Question: How to get the raw text of port defined type
tsyw opened this issue · 1 comments
tsyw commented
Hello,
I want to use the python binding as a library to extract some design related information. However, I found that I cannot get the raw text using PortSymbol.type.
Example:
input [ADDR_WIDTH-1:0] addr;
It is great to get the real width after parsing the .v file. But maybe the raw text combined with InstanceBodySymbol.parameters is also a good way for changing the actual width when instantiating the modules.
MikePopoloski commented
You can get the syntax node by looking at the port symbol's internalSymbol.declaredType.typeSyntax or internalExpr.syntax.