Home
last modified time | relevance | path

Searched refs:FormatStyle (Results 1 – 25 of 41) sorted by relevance

12

/freebsd-14.2/contrib/llvm-project/clang/lib/Format/
H A DFormat.cpp1169 Style.LineEnding = UseCRLF ? FormatStyle::LE_CRLF : FormatStyle::LE_LF; in mapping()
1209 static FormatStyle &element(IO &IO, std::vector<FormatStyle> &Seq, in element()
1402 FormatStyle getLLVMStyle(FormatStyle::LanguageKind Language) { in getLLVMStyle()
1403 FormatStyle LLVMStyle; in getLLVMStyle()
1611 FormatStyle getGoogleStyle(FormatStyle::LanguageKind Language) { in getGoogleStyle()
1613 FormatStyle GoogleStyle = getGoogleStyle(FormatStyle::LK_Proto); in getGoogleStyle()
1753 FormatStyle getChromiumStyle(FormatStyle::LanguageKind Language) { in getChromiumStyle()
1878 FormatStyle getMicrosoftStyle(FormatStyle::LanguageKind Language) { in getMicrosoftStyle()
2068 FormatStyle::FormatStyleSet::Get(FormatStyle::LanguageKind Language) const { in Get()
2079 void FormatStyle::FormatStyleSet::Add(FormatStyle Style) { in Add()
[all …]
H A DContinuationIndenter.cpp197 const FormatStyle &CodeStyle) { in RawStringFormatStyleManager()
202 FormatStyle PredefinedStyle; in RawStringFormatStyleManager()
218 std::optional<FormatStyle>
226 std::optional<FormatStyle>
547 case FormatStyle::BBCDS_Allowed: in mustBreak()
549 case FormatStyle::BBCDS_Always: in mustBreak()
551 case FormatStyle::BBCDS_Never: in mustBreak()
557 case FormatStyle::RCPS_SingleLine: in mustBreak()
1341 case FormatStyle::RCPS_OwnLine: in getNewLineColumn()
1342 case FormatStyle::RCPS_WithFollowing: in getNewLineColumn()
[all …]
H A DContinuationIndenter.h40 llvm::StringMap<FormatStyle> DelimiterStyle;
41 llvm::StringMap<FormatStyle> EnclosingFunctionStyle;
43 RawStringFormatStyleManager(const FormatStyle &CodeStyle);
45 std::optional<FormatStyle> getDelimiterStyle(StringRef Delimiter) const;
47 std::optional<FormatStyle>
55 ContinuationIndenter(const FormatStyle &Style,
114 const FormatStyle &RawStringStyle,
124 std::optional<FormatStyle> getRawStringStyle(const FormatToken &Current,
192 FormatStyle Style;
H A DTokenAnnotator.cpp30 case FormatStyle::ABS_Always: in mustBreakAfterAttributes()
32 case FormatStyle::ABS_Leave: in mustBreakAfterAttributes()
2708 const FormatStyle &Style;
3118 const FormatStyle &Style;
3436 case FormatStyle::RTBS_None: in mustBreakForReturnType()
3438 case FormatStyle::RTBS_All: in mustBreakForReturnType()
5045 case FormatStyle::SLS_All: in mustBreakBefore()
5811 case FormatStyle::RAS_Left: in getTokenReferenceAlignment()
5813 case FormatStyle::RAS_Right: in getTokenReferenceAlignment()
5815 case FormatStyle::RAS_Middle: in getTokenReferenceAlignment()
[all …]
H A DUnwrappedLineFormatter.cpp167 const FormatStyle &Style;
323 FormatStyle::SFS_InlineOnly) { in tryFitMultipleLinesInOne()
647 FormatStyle::SIS_WithoutElse) { in tryMergeSimpleControlStatement()
935 const FormatStyle &Style;
1084 const FormatStyle &Style;
1488 case FormatStyle::ELBAMS_Never: in computeNewlines()
1492 case FormatStyle::ELBAMS_Leave: in computeNewlines()
1501 case FormatStyle::ELBAMS_Always: { in computeNewlines()
1522 case FormatStyle::ELAAMS_Never: in computeNewlines()
1525 case FormatStyle::ELAAMS_Leave: in computeNewlines()
[all …]
H A DBreakableToken.h34 struct FormatStyle;
240 encoding::Encoding Encoding, const FormatStyle &Style) in BreakableToken()
247 const FormatStyle &Style;
259 encoding::Encoding Encoding, const FormatStyle &Style);
307 encoding::Encoding Encoding, const FormatStyle &Style);
338 const FormatStyle &Style);
406 const FormatStyle &Style, bool UseCRLF);
484 const FormatStyle &Style);
H A DIntegerLiteralSeparatorFixer.cpp46 const FormatStyle &Style) { in process()
48 case FormatStyle::LK_Cpp: in process()
49 case FormatStyle::LK_ObjC: in process()
52 case FormatStyle::LK_CSharp: in process()
53 case FormatStyle::LK_Java: in process()
54 case FormatStyle::LK_JavaScript: in process()
H A DDefinitionBlockSeparator.cpp25 assert(Style.SeparateDefinitionBlocks != FormatStyle::SDS_Leave); in analyze()
36 Style.SeparateDefinitionBlocks == FormatStyle::SDS_Never; in separateBlocks()
69 (Style.SeparateDefinitionBlocks == FormatStyle::SDS_Always ? 1 : 0) + 1; in separateBlocks()
72 Style.LineEnding > FormatStyle::LE_CRLF in separateBlocks()
75 Style.LineEnding == FormatStyle::LE_DeriveCRLF) in separateBlocks()
76 : Style.LineEnding == FormatStyle::LE_CRLF); in separateBlocks()
H A DTokenAnnotator.h214 TokenAnnotator(const FormatStyle &Style, const AdditionalKeywords &Keywords) in TokenAnnotator()
255 FormatStyle::PointerAlignmentStyle
258 FormatStyle::PointerAlignmentStyle getTokenPointerOrReferenceAlignment(
261 const FormatStyle &Style;
H A DWhitespaceManager.cpp463 if ((Style.PointerAlignment == FormatStyle::PAS_Right || in AlignTokenSequence()
464 Style.ReferenceAlignment == FormatStyle::RAS_Right) && in AlignTokenSequence()
467 Style.ReferenceAlignment != FormatStyle::RAS_Right && in AlignTokenSequence()
468 Style.ReferenceAlignment != FormatStyle::RAS_Pointer; in AlignTokenSequence()
1253 if (Style.AlignArrayOfStructures == FormatStyle::AIAS_None) in alignArrayInitializers()
1278 if (Style.AlignArrayOfStructures == FormatStyle::AIAS_Right) in alignArrayInitializers()
1699 case FormatStyle::UT_Never: in appendIndentText()
1702 case FormatStyle::UT_Always: { in appendIndentText()
1723 case FormatStyle::UT_ForIndentation: in appendIndentText()
1730 case FormatStyle::UT_ForContinuationAndIndentation: in appendIndentText()
[all …]
H A DUnwrappedLineParser.cpp150 SourceManager &SourceMgr, const FormatStyle &Style, in UnwrappedLineParser()
266 if (Style.Language == FormatStyle::LK_TextProto) in parseFile()
280 if (Style.Language == FormatStyle::LK_TextProto && in parseFile()
1544 if (Style.Language == FormatStyle::LK_Proto) { in parseStructuralElement()
1727 FormatStyle::BWACS_Always) { in parseStructuralElement()
1742 FormatStyle::BWACS_Always) { in parseStructuralElement()
1894 FormatStyle::BWACS_Always) { in parseStructuralElement()
3095 if (Style.Language != FormatStyle::LK_Java) in parseNew()
3223 FormatStyle::BWACS_Always) { in parseLabel()
3757 if (Style.Language == FormatStyle::LK_Java) { in parseEnum()
[all …]
H A DUnwrappedLineFormatter.h32 const FormatStyle &Style, in UnwrappedLineFormatter()
68 const FormatStyle &Style;
H A DTokenAnalyzer.h90 TokenAnalyzer(const Environment &Env, const FormatStyle &Style);
105 FormatStyle Style;
H A DUsingDeclarationsSorter.cpp88 FormatStyle::SortUsingDeclarationsOptions SortUsingDeclarations) { in compareLabels()
89 if (SortUsingDeclarations == FormatStyle::SUD_LexicographicNumeric) in compareLabels()
140 FormatStyle::SortUsingDeclarationsOptions SortUsingDeclarations) { in endUsingDeclarationBlock()
209 const FormatStyle &Style) in UsingDeclarationsSorter()
H A DQualifierAlignmentFixer.h27 void addQualifierAlignmentFixerPasses(const FormatStyle &Style,
43 const Environment &Env, const FormatStyle &Style,
H A DBreakableToken.cpp43 const FormatStyle &Style) { in getLineCommentIndentPrefix()
49 if (Style.Language == FormatStyle::LK_TextProto) in getLineCommentIndentPrefix()
70 encoding::Encoding Encoding, const FormatStyle &Style, in getCommentSplit()
270 encoding::Encoding Encoding, const FormatStyle &Style) in BreakableStringLiteral()
298 encoding::Encoding Encoding, const FormatStyle &Style) in BreakableStringLiteralUsingOperators()
316 Style.BreakBeforeBinaryOperators != FormatStyle::BOS_None; in BreakableStringLiteralUsingOperators()
352 Style.AlignOperands == FormatStyle::OAS_AlignAfterOperator) { in BreakableStringLiteralUsingOperators()
412 const FormatStyle &Style) in BreakableComment()
579 if (Style.isJavaScript() || Style.Language == FormatStyle::LK_Java) { in BreakableBlockComment()
697 if (Style.Language != FormatStyle::LK_Java && !Style.isJavaScript()) in getContentIndent()
[all …]
H A DFormatToken.cpp78 bool FormatToken::isBlockIndentedInitRBrace(const FormatStyle &Style) const { in isBlockIndentedInitRBrace()
81 Style.AlignAfterOpenBracket != FormatStyle::BAS_BlockIndent) { in isBlockIndentedInitRBrace()
93 bool FormatToken::opensBlockOrBlockTypeList(const FormatStyle &Style) const { in opensBlockOrBlockTypeList()
210 if (Style.AlignAfterOpenBracket == FormatStyle::BAS_DontAlign) in precomputeFormattingInfos()
H A DFormatTokenLexer.h43 const FormatStyle &Style, encoding::Encoding Encoding,
126 const FormatStyle &Style;
H A DMacros.h104 clang::SourceManager &SourceMgr, const FormatStyle &Style,
134 const FormatStyle &Style;
H A DSortJavaScriptImports.h27 tooling::Replacements sortJavaScriptImports(const FormatStyle &Style,
H A DFormatInternal.h72 reformat(const FormatStyle &Style, StringRef Code,
H A DUsingDeclarationsSorter.h25 UsingDeclarationsSorter(const Environment &Env, const FormatStyle &Style);
H A DIntegerLiteralSeparatorFixer.h26 const FormatStyle &Style);
/freebsd-14.2/contrib/llvm-project/clang/include/clang/Format/
H A DFormat.h55 struct FormatStyle { struct
4933 typedef std::map<FormatStyle::LanguageKind, FormatStyle> MapType;
4935 std::optional<FormatStyle> Get(FormatStyle::LanguageKind Language) const;
4967 FormatStyle getLLVMStyle(
4968 FormatStyle::LanguageKind Language = FormatStyle::LanguageKind::LK_Cpp);
4974 FormatStyle getGoogleStyle(FormatStyle::LanguageKind Language);
4978 FormatStyle getChromiumStyle(FormatStyle::LanguageKind Language);
4990 FormatStyle getGNUStyle();
4994 FormatStyle getMicrosoftStyle(FormatStyle::LanguageKind Language);
4999 FormatStyle getNoStyle();
[all …]
/freebsd-14.2/contrib/llvm-project/clang/tools/clang-format/
H A DClangFormat.cpp443 llvm::Expected<FormatStyle> FormatStyle = in format() local
446 if (!FormatStyle) { in format()
453 FormatStyle->QualifierAlignment = in format()
460 if (FormatStyle->QualifierAlignment == FormatStyle::QAS_Left) { in format()
462 } else if (FormatStyle->QualifierAlignment == FormatStyle::QAS_Right) { in format()
465 FormatStyle->QualifierAlignment = FormatStyle::QAS_Custom; in format()
474 FormatStyle->SortIncludes = FormatStyle::SI_CaseSensitive; in format()
476 FormatStyle->SortIncludes = FormatStyle::SI_Never; in format()
484 if (FormatStyle->isJson() && !FormatStyle->DisableFormat) { in format()
563 llvm::Expected<clang::format::FormatStyle> FormatStyle = in dumpConfig() local
[all …]

12