clang: clang::format::UnwrappedLine Struct Reference (original) (raw)
An unwrapped line is a sequence of [Token](classclang%5F1%5F1Token.html "Token - This structure provides full information about a lexed token.")
, that we would like to put on a single line if there was no column limit. More...
#include "[/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/Format/UnwrappedLineParser.h](UnwrappedLineParser%5F8h%5Fsource.html)"
Public Attributes | |
---|---|
std::list< UnwrappedLineNode > | Tokens |
The Tokens comprising this UnwrappedLine. | |
unsigned | Level = 0 |
The indent level of the UnwrappedLine. | |
unsigned | PPLevel = 0 |
The PPBranchLevel (adjusted for header guards) if this line is a InMacroBody line, and 0 otherwise. | |
bool | InPPDirective = false |
Whether this UnwrappedLine is part of a preprocessor directive. | |
bool | InPragmaDirective = false |
Whether this UnwrappedLine is part of a pramga directive. | |
bool | InMacroBody = false |
Whether it is part of a macro body. | |
unsigned | UnbracedBodyLevel = 0 |
Nesting level of unbraced body of a control statement. | |
bool | MustBeDeclaration = false |
bool | SeenDecltypeAuto = false |
Whether the parser has seen decltype(auto) in this line. | |
bool | IsContinuation = false |
True if this line should be indented by ContinuationIndent in addition to the normal indention level. | |
size_t | MatchingOpeningBlockLineIndex = kInvalidIndex |
If this UnwrappedLine closes a block in a sequence of lines, MatchingOpeningBlockLineIndex stores the index of the corresponding opening line. | |
size_t | MatchingClosingBlockLineIndex = kInvalidIndex |
If this UnwrappedLine opens a block, stores the index of the line with the corresponding closing brace. | |
unsigned | FirstStartColumn = 0 |
An unwrapped line is a sequence of [Token](classclang%5F1%5F1Token.html "Token - This structure provides full information about a lexed token.")
, that we would like to put on a single line if there was no column limit.
This is used as a main interface between the [UnwrappedLineParser](classclang%5F1%5F1format%5F1%5F1UnwrappedLineParser.html)
and the [UnwrappedLineFormatter](classclang%5F1%5F1format%5F1%5F1UnwrappedLineFormatter.html)
. The key property is that changing the formatting within an unwrapped line does not affect any other unwrapped lines.
Definition at line 32 of file UnwrappedLineParser.h.
clang::format::UnwrappedLine::UnwrappedLine ( ) | default |
---|
◆ FirstStartColumn
unsigned clang::format::UnwrappedLine::FirstStartColumn = 0
◆ InMacroBody
bool clang::format::UnwrappedLine::InMacroBody = false
◆ InPPDirective
bool clang::format::UnwrappedLine::InPPDirective = false
◆ InPragmaDirective
bool clang::format::UnwrappedLine::InPragmaDirective = false
◆ IsContinuation
bool clang::format::UnwrappedLine::IsContinuation = false
True
if this line should be indented by ContinuationIndent in addition to the normal indention level.
Definition at line 62 of file UnwrappedLineParser.h.
◆ kInvalidIndex
const size_t clang::format::UnwrappedLine::kInvalidIndex = -1 | static |
---|
◆ Level
unsigned clang::format::UnwrappedLine::Level = 0
◆ MatchingClosingBlockLineIndex
◆ MatchingOpeningBlockLineIndex
If this [UnwrappedLine](structclang%5F1%5F1format%5F1%5F1UnwrappedLine.html "An unwrapped line is a sequence of Token, that we would like to put on a single line if there was no ...")
closes a block in a sequence of lines, MatchingOpeningBlockLineIndex
stores the index of the corresponding opening line.
Otherwise, MatchingOpeningBlockLineIndex
must be kInvalidIndex
.
Definition at line 68 of file UnwrappedLineParser.h.
◆ MustBeDeclaration
bool clang::format::UnwrappedLine::MustBeDeclaration = false
◆ PPLevel
unsigned clang::format::UnwrappedLine::PPLevel = 0
The PPBranchLevel
(adjusted for header guards) if this line is a InMacroBody
line, and 0 otherwise.
Definition at line 43 of file UnwrappedLineParser.h.
◆ SeenDecltypeAuto
bool clang::format::UnwrappedLine::SeenDecltypeAuto = false
◆ Tokens
◆ UnbracedBodyLevel
unsigned clang::format::UnwrappedLine::UnbracedBodyLevel = 0
The documentation for this struct was generated from the following file:
- lib/Format/UnwrappedLineParser.h