zachjs / sv2v

SystemVerilog to Verilog conversion
BSD 3-Clause "New" or "Revised" License
561 stars 55 forks source link

Multi-line macro calls with comments in the middle cause errors #153

Closed mkorbel1 closed 3 years ago

mkorbel1 commented 3 years ago

If a macro is multiple lines, and one of those lines is a comment, it can cause all kinds of errors from sv2v including 'wrong number of arguments' or 'unexpected end of file' type errors.

For example:

`MYMACRO(A,
// this is a comment
B)
zachjs commented 3 years ago

Thank you for finding and reporting this issue! As of 9aa8b7033e71161cb291aa72288c9f3393b3456d, comments are now handled within macro arguments, for both macro definitions and macro invocations. Please let me know if it works for you!

mkorbel1 commented 3 years ago

Yes, it works! Thanks!