clang 22.0.0git
|
#include "/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/Format/FormatToken.h"
Public Member Functions | |
TokenRole (const FormatStyle &Style) | |
virtual | ~TokenRole () |
virtual void | precomputeFormattingInfos (const FormatToken *Token) |
After the TokenAnnotator has finished annotating all the tokens, this function precomputes required information for formatting. | |
virtual unsigned | formatFromToken (LineState &State, ContinuationIndenter *Indenter, bool DryRun) |
Apply the special formatting that the given role demands. | |
virtual unsigned | formatAfterToken (LineState &State, ContinuationIndenter *Indenter, bool DryRun) |
Same as formatFromToken , but assumes that the first token has already been set thereby deciding on the first line break. | |
virtual void | CommaFound (const FormatToken *Token) |
Notifies the Role that a comma was found. | |
virtual const FormatToken * | lastComma () |
Protected Attributes | |
const FormatStyle & | Style |
Definition at line 928 of file FormatToken.h.
|
inline |
Definition at line 930 of file FormatToken.h.
References Style, and TokenRole().
Referenced by TokenRole().
|
virtual |
Definition at line 82 of file FormatToken.cpp.
|
inlinevirtual |
Notifies the Role
that a comma was found.
Reimplemented in clang::CommaSeparatedList.
Definition at line 958 of file FormatToken.h.
|
inlinevirtual |
Same as formatFromToken
, but assumes that the first token has already been set thereby deciding on the first line break.
Reimplemented in clang::CommaSeparatedList.
Definition at line 951 of file FormatToken.h.
|
inlinevirtual |
Apply the special formatting that the given role demands.
Assumes that the token having this role is already formatted.
Continues formatting from State
leaving indentation to Indenter
and returns the total penalty that this formatting incurs.
Reimplemented in clang::CommaSeparatedList.
Definition at line 943 of file FormatToken.h.
References formatFromToken().
Referenced by formatFromToken().
|
inlinevirtual |
Reimplemented in clang::CommaSeparatedList.
Definition at line 960 of file FormatToken.h.
|
virtual |
After the TokenAnnotator
has finished annotating all the tokens, this function precomputes required information for formatting.
Reimplemented in clang::CommaSeparatedList.
Definition at line 84 of file FormatToken.cpp.
References FormatToken().
|
protected |
Definition at line 963 of file FormatToken.h.
Referenced by clang::CommaSeparatedList::CommaSeparatedList(), clang::CommaSeparatedList::formatAfterToken(), clang::CommaSeparatedList::precomputeFormattingInfos(), and TokenRole().