Skip to main content

Module comments

Module comments 

Source
Expand description

The text of a comment, which one rule changes: SpacesInLineCommentPrefix.

clang-format (23.1.5, LLVM) normalises //using to // using and //!bang to //! bang, while leaving already spaced text and the decorators alone — measured:

//using enum X;   ->  // using enum X;
///doc comment    ->  /// doc comment
//!bang           ->  //! bang
//:ref            ->  //: ref
//  two spaces    ->  //  two spaces      (unchanged: at least one, at most unlimited)
//NOLINT          ->  // NOLINT

The prefix is // followed by the run of /, ! and : that makes it a doc/reference marker; the option’s Minimum is the spaces that must follow it, and its Maximum (unlimited by default) the most that may.

Functions§

normalized
The comment’s text with the configured spacing after its prefix.