The Verilog to html converter
To get e-mail when I update v2html, enter your
address and click "Add Me" (over 560 people already have).
How ifdefs are handled
Because v2html parses your verilog it has to handle ifdefs too, otherwise it would get confused by stuff like this:
begin i = i + 1; `ifdef SOMETHING end `else end `endif
The way it handles ifdefs is to keep track of what is defined at the moment by looking at the `defines in your file (and in any included files that it has access to) and ignore the code that is ifdefed out.
It also 'greys out' any code that is ifdefed out when it comes to producing the html. You can turn off the greying out with the -ni command line option, but v2html will still ignore the code while it is parsing.
You can also specify defines on the command line in the verilog syntax, either:
v2html +define+NAME1 +define+NAME2 ...
or
v2html +define+NAME=VALUE ...
Here is an example of code with loads of ifdefs in.
© 1999-2009 Costas Calamvokis