Repository navigation
v0.2.4
What's Changed
Better error messages for invalid port references
Invalid port references (e.g. add.Carry31 where Carry31 doesn't exist on Adder32) now produce clear, actionable errors:
error[E0304]: Unknown port 'Carry31' on component 'Adder32'
--> addSub32.shdl:10:9
|
10 | add.Carry31 -> S[1];
| ^
= note: available ports: A, B, Cin, S, Cout
Previously this would produce the confusing message "Unknown instance 'add'".
Changes
- Integrated the existing semantic analyzer into the flattener pipeline — it now runs automatically before flattening
- Added defensive guards in the flattener's rewire functions to catch unmapped ports
Flatteneraccepts avalidateparameter (defaultTrue) to control semantic validation