forked from qt-creator/qt-creator
ClangFormat: Adapt to changes in LLVM 16
Change-Id: Ia4a2cf21e351095609d8858f1f9355c6607470f3 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -38,7 +38,11 @@ void adjustFormatStyleForLineBreak(clang::format::FormatStyle &style,
|
||||
#else
|
||||
style.SortIncludes = false;
|
||||
#endif
|
||||
#if LLVM_VERSION_MAJOR >= 16
|
||||
style.SortUsingDeclarations = clang::format::FormatStyle::SUD_Never;
|
||||
#else
|
||||
style.SortUsingDeclarations = false;
|
||||
#endif
|
||||
|
||||
// This is a separate pass, don't do it unless it's the full formatting.
|
||||
style.FixNamespaceComments = false;
|
||||
|
||||
@@ -151,7 +151,11 @@ clang::format::FormatStyle qtcStyle()
|
||||
#else
|
||||
style.SortIncludes = true;
|
||||
#endif
|
||||
#if LLVM_VERSION_MAJOR >= 16
|
||||
style.SortUsingDeclarations = FormatStyle::SUD_Lexicographic;
|
||||
#else
|
||||
style.SortUsingDeclarations = true;
|
||||
#endif
|
||||
style.SpaceAfterCStyleCast = true;
|
||||
style.SpaceAfterTemplateKeyword = false;
|
||||
style.SpaceBeforeAssignmentOperators = true;
|
||||
|
||||
Reference in New Issue
Block a user