tree: f9b48b87e07e81069746dfc60c03b5ebddf15391 [path history] [tgz]
  1. align.cc
  2. align.h
  3. BUILD
  4. comment_controls.cc
  5. comment_controls.h
  6. comment_controls_test.cc
  7. format_style.h
  8. format_style_init.cc
  9. format_style_init.h
  10. formatter.cc
  11. formatter.h
  12. formatter_test.cc
  13. formatter_tuning_test.cc
  14. README.md
  15. token_annotator.cc
  16. token_annotator.h
  17. token_annotator_test.cc
  18. tree_unwrapper.cc
  19. tree_unwrapper.h
  20. tree_unwrapper_test.cc
  21. verilog_token.cc
  22. verilog_token.h
  23. verilog_token_test.cc
verilog/formatting/README.md

SystemVerilog Formatting

This directory contains all of the SystemVerilog-specific formatter implementation.

Tool user documentation can be found here.

Formatter Subsystems

Full developer documentation can be found here.

Below is a quick summary of the major components.

formatter.h contains the top-level entry point into the formatter. Text-in-text-out tests are in formatter_test.cc.

FormatStyle defines ways in which formatting can be configured.

token_annotator.h marks up a token stream with formatting constraints such as minimum spacing, and always/never-wrap.

TreeUnwrapper converts a SV syntax tree into a language-agnostic TokenPartitionTree representation for doing formatting operations.

align.h implements everything related to tabular alignment of specific sections of code.

comment_controls.h implements comment directives thet disable formatting on ranges of text.