clang  14.0.0git
Public Member Functions | Static Public Member Functions | List of all members
clang::format::LeftRightQualifierAlignmentFixer Class Reference

#include "/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/Format/QualifierAlignmentFixer.h"

Inheritance diagram for clang::format::LeftRightQualifierAlignmentFixer:
Inheritance graph
[legend]
Collaboration diagram for clang::format::LeftRightQualifierAlignmentFixer:
Collaboration graph
[legend]

Public Member Functions

 LeftRightQualifierAlignmentFixer (const Environment &Env, const FormatStyle &Style, const std::string &Qualifier, const std::vector< tok::TokenKind > &ConfiguredQualifierTokens, bool RightAlign)
 
std::pair< tooling::Replacements, unsignedanalyze (TokenAnnotator &Annotator, SmallVectorImpl< AnnotatedLine * > &AnnotatedLines, FormatTokenLexer &Tokens) override
 
FormatTokenanalyzeRight (const SourceManager &SourceMgr, const AdditionalKeywords &Keywords, tooling::Replacements &Fixes, FormatToken *Tok, const std::string &Qualifier, tok::TokenKind QualifierType)
 
FormatTokenanalyzeLeft (const SourceManager &SourceMgr, const AdditionalKeywords &Keywords, tooling::Replacements &Fixes, FormatToken *Tok, const std::string &Qualifier, tok::TokenKind QualifierType)
 
- Public Member Functions inherited from clang::format::TokenAnalyzer
 TokenAnalyzer (const Environment &Env, const FormatStyle &Style)
 
std::pair< tooling::Replacements, unsignedprocess ()
 
- Public Member Functions inherited from clang::format::UnwrappedLineConsumer
virtual ~UnwrappedLineConsumer ()
 

Static Public Member Functions

static tok::TokenKind getTokenFromQualifier (const std::string &Qualifier)
 
static bool isQualifierOrType (const FormatToken *Tok, const std::vector< tok::TokenKind > &Qualifiers)
 
static bool isPossibleMacro (const FormatToken *Tok)
 

Additional Inherited Members

- Protected Member Functions inherited from clang::format::TokenAnalyzer
void consumeUnwrappedLine (const UnwrappedLine &TheLine) override
 
void finishRun () override
 
- Protected Attributes inherited from clang::format::TokenAnalyzer
FormatStyle Style
 
const EnvironmentEnv
 
AffectedRangeManager AffectedRangeMgr
 
SmallVector< SmallVector< UnwrappedLine, 16 >, 2 > UnwrappedLines
 
encoding::Encoding Encoding
 

Detailed Description

Definition at line 55 of file QualifierAlignmentFixer.h.

Constructor & Destructor Documentation

◆ LeftRightQualifierAlignmentFixer()

clang::format::LeftRightQualifierAlignmentFixer::LeftRightQualifierAlignmentFixer ( const Environment Env,
const FormatStyle Style,
const std::string Qualifier,
const std::vector< tok::TokenKind > &  ConfiguredQualifierTokens,
bool  RightAlign 
)

Definition at line 376 of file QualifierAlignmentFixer.cpp.

Member Function Documentation

◆ analyze()

std::pair< tooling::Replacements, unsigned > clang::format::LeftRightQualifierAlignmentFixer::analyze ( TokenAnnotator Annotator,
SmallVectorImpl< AnnotatedLine * > &  AnnotatedLines,
FormatTokenLexer Tokens 
)
overridevirtual

Implements clang::format::TokenAnalyzer.

Definition at line 384 of file QualifierAlignmentFixer.cpp.

◆ analyzeLeft()

FormatToken * clang::format::LeftRightQualifierAlignmentFixer::analyzeLeft ( const SourceManager SourceMgr,
const AdditionalKeywords Keywords,
tooling::Replacements Fixes,
FormatToken Tok,
const std::string Qualifier,
tok::TokenKind  QualifierType 
)

Definition at line 282 of file QualifierAlignmentFixer.cpp.

◆ analyzeRight()

FormatToken * clang::format::LeftRightQualifierAlignmentFixer::analyzeRight ( const SourceManager SourceMgr,
const AdditionalKeywords Keywords,
tooling::Replacements Fixes,
FormatToken Tok,
const std::string Qualifier,
tok::TokenKind  QualifierType 
)

Definition at line 205 of file QualifierAlignmentFixer.cpp.

◆ getTokenFromQualifier()

tok::TokenKind clang::format::LeftRightQualifierAlignmentFixer::getTokenFromQualifier ( const std::string Qualifier)
static

◆ isPossibleMacro()

bool clang::format::LeftRightQualifierAlignmentFixer::isPossibleMacro ( const FormatToken Tok)
static

◆ isQualifierOrType()

bool clang::format::LeftRightQualifierAlignmentFixer::isQualifierOrType ( const FormatToken Tok,
const std::vector< tok::TokenKind > &  Qualifiers 
)
static

The documentation for this class was generated from the following files: