DVT IDE for VS Code SystemVerilog User Guide
Rev. 23.1.12, 23 May 2023

19.2 Indentation

  • Optional Begin - Controls the placement of optional `begin`:

    • Leave as is

    • On a new line - begin is moved on a new line

    • On the same line - begin is moved on the same line with it's construct

    • On a new line and indent - begin is moved on a new line and indented

  • Else - Controls the placement of `else`:

    • Leave as is

    • On a new line - else is moved on a new line

    • On the same line - if end precedes it else is moved on the same line with end

  • Parameters - Controls the placement of module ports and parameters, function and task arguments, class parameters:

    • Leave as is

    • One per line (open parenthesis on the same line) - each parameter/argument is placed on it's own line and the open parentheses is placed on the same line with the parameter/argument receiver

    • One per line (open parenthesis on the next line) - each parameter/argument is placed on it's own line and the open parentheses is placed on the next line after the parameter/argument receiver

    • More per line - more are placed on the same line, as fit when line wrapping is enabled

  • Preprocessing - Controls the indentation of preprocessing blocks:

    • Leave as is

    • Indent - indent the preprocessing block according to the enclosing scope without increasing the enclosed code indentation

    • Indent and increase indentation level - indent the preprocessing block according to the enclosing scope and increase the enclosed code indentation

    • Indent and increase indentation level - except first - indent the preprocessing block according to the enclosing scope and increase the enclosed code indentation with the exception of the first nested preprocessing block

    • Move at first column - reset the preprocessing block indentation

  • Do Not Indent Single Line Comments At Beginning Of Line - Controls whether to indent single line comments starting at the beginning of a line.

  • Indent Multi Line Comments - Controls whether to indent multi-line comments.

  • Indent Multi-line Assigns - Controls whether to indent multi-line assigns.

  • Add New Line After Begin And Before End - Controls whether to add a new line after `begin` and before `end`.

  • Add New Line After End - Controls whether to add a new line after `end`.

  • Ignore Lines Starting With - List of line prefixes matching lines that will be ignored while indenting.

  • No Indent Keywords - Selection of language keywords that will not increase indentation.

  • Implicit Semi Macros - List of macros encapsulating *semicolon* or *end* delimiters.

  • Open Scope Macros - List of macros that open a scope and increase the indentation of subsequent code.

  • Close Scope Macros - List of macros that close a scope and decrease the indentation of subsequent code.