Skip to content

Add support for multi-style block comments#1543

Open
lzulberti wants to merge 3 commits intojeremiah-c-leary:masterfrom
lzulberti:feature/multiple-block-comments
Open

Add support for multi-style block comments#1543
lzulberti wants to merge 3 commits intojeremiah-c-leary:masterfrom
lzulberti:feature/multiple-block-comments

Conversation

@lzulberti
Copy link
Copy Markdown

Description

This PR adds support for configuring multiple block comment styles by allowing array-valued configuration entries in:

  • block_comment_001
  • block_comment_002
  • block_comment_003

Each position in the arrays represents one complete block comment style, and the same index is applied consistently across header, body, and footer. This makes it possible to define several valid block comment formats within the same project.

The change is backward compatible: existing single-value configurations continue to work as before and are internally handled as a single-style configuration.

This PR also enables autofix support for block comment separator normalization, for example by rebuilding header/footer separator lines to the configured length when the style can be determined safely.

Motivation

Some projects use more than one block comment convention, for example:

  • section separators
  • subsection separators
  • doxygen documentation blocks

At the moment, the configuration supports only one block comment style at a time. This PR removes that limitation.

Example

Supported block comment styles may include:

--|==================================================================================
--| Section
--|==================================================================================

--|-----------------------------------------------------------------------------
--| Sub-section
--|-----------------------------------------------------------------------------

--! @brief Architecture definition of ..... entity
--! @details Architecture ....
--!    ....
--!    ....

@lzulberti lzulberti force-pushed the feature/multiple-block-comments branch from 13b5fae to 93c2731 Compare March 24, 2026 12:25
@lzulberti lzulberti force-pushed the feature/multiple-block-comments branch from 93c2731 to 68c41d2 Compare March 24, 2026 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant