https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/135520
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/135516
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/135479
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/135466
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/135137
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks closed
https://github.com/llvm/llvm-project/pull/135137
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -33,7 +33,7 @@ to format C/C++/Java/JavaScript/JSON/Objective-C/Protobuf/C#
code.
Clang-format options:
--Werror - If set, changes formatting warnings to
errors
---Wno-error=- If set, don't error out on the specified
warning ty
https://github.com/HazardyKnusperkeks commented:
I think you should also update:
* `git-clang-format`
* The help text in `ClangFormat.cpp`
* Run `clang/docs/tools/dump_format_help.py`
* `clang-format-diff.py`
https://github.com/llvm/llvm-project/pull/135137
__
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/135035
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/134973
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
But why does this fix it?
https://github.com/llvm/llvm-project/pull/134472
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-com
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/134473
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/133722
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1067,6 +1076,8 @@ template <> struct MappingTraits {
IO.mapOptional("InsertNewlineAtEOF", Style.InsertNewlineAtEOF);
IO.mapOptional("InsertTrailingCommas", Style.InsertTrailingCommas);
IO.mapOptional("IntegerLiteralSeparator", Style.IntegerLiteralSeparator);
+
HazardyKnusperkeks wrote:
> FAIL: Clang :: Format/docs_updated.test (12079 of 22139)
You forgot to redo the documentation.
https://github.com/llvm/llvm-project/pull/131605
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/
@@ -2031,6 +2031,7 @@ class SourceManagerForFile {
// The order of these fields are important - they should be in the same order
// as they are created in `createSourceManagerForFile` so that they can be
// deleted in the reverse order as they are created.
+ std::string
@@ -498,6 +498,8 @@ clang-format
top of the file.
- Add ``EnumTrailingComma`` option for inserting/removing commas at the end of
``enum`` enumerator lists.
+- Allow to apply parameters bin-packing options to function-like macros that
+ use keywords to delimit parameters (e
@@ -3926,6 +3926,39 @@ TEST_F(TokenAnnotatorTest,
UserDefinedConversionFunction) {
EXPECT_TOKEN(Tokens[5], tok::l_paren, TT_FunctionDeclarationLParen);
}
+TEST_F(TokenAnnotatorTest, KeywordedFunctionLikeMacro) {
+ auto Style = getLLVMStyle();
+ FormatStyle::KeywordedFunct
HazardyKnusperkeks wrote:
> > IMO, a boolean option, e.g. `AllowBreakBeforeQPropertyKeyword` should
> > suffice.
>
> I don't like to hardcode neither the macro name nor the keywords, which
> depend on Qt version. Implementation would not differ save for the source we
> fetch keywords from.
I
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/133673
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -2214,6 +2214,21 @@ FormatStyle::GetLanguageStyle(FormatStyle::LanguageKind
Language) const {
namespace {
+void replaceToken(const FormatToken &Token, FormatToken *Next,
+ const SourceManager &SourceMgr, tooling::Replacements
&Result,
+
@@ -2214,6 +2214,21 @@ FormatStyle::GetLanguageStyle(FormatStyle::LanguageKind
Language) const {
namespace {
+void replaceToken(const FormatToken &Token, FormatToken *Next,
+ const SourceManager &SourceMgr, tooling::Replacements
&Result,
+
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/133576
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -15120,6 +15120,85 @@ TEST_F(FormatTest,
PullInlineFunctionDefinitionsIntoSingleLine) {
MergeInlineOnly);
}
+TEST_F(FormatTest, PullStaticInlineFunctionDefinitionsIntoSingleLine) {
+ FormatStyle MergeStaticInlineOnly = getLLVMStyle();
+ MergeStaticInlineOn
https://github.com/HazardyKnusperkeks approved this pull request.
Should this get the same warning as the other non white space changes?
https://github.com/llvm/llvm-project/pull/133576
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://li
@@ -335,6 +336,32 @@ class LineJoiner {
}
}
+ if (Style.AllowShortFunctionsOnASingleLine ==
+ FormatStyle::SFS_StaticInlineOnly ||
+ Style.AllowShortFunctionsOnASingleLine ==
+ FormatStyle::SFS_StaticInline) {
+// C
@@ -863,6 +870,12 @@ struct FormatStyle {
/// void f() {}
/// \endcode
SFS_Inline,
+/// Only merge functions defined as static inline. Implies ``empty``.
HazardyKnusperkeks wrote:
This should have a different text.
https://github.com/llvm/ll
@@ -335,6 +336,32 @@ class LineJoiner {
}
}
+ if (Style.AllowShortFunctionsOnASingleLine ==
+ FormatStyle::SFS_StaticInlineOnly ||
+ Style.AllowShortFunctionsOnASingleLine ==
+ FormatStyle::SFS_StaticInline) {
+// C
@@ -15120,6 +15120,85 @@ TEST_F(FormatTest,
PullInlineFunctionDefinitionsIntoSingleLine) {
MergeInlineOnly);
}
+TEST_F(FormatTest, PullStaticInlineFunctionDefinitionsIntoSingleLine) {
+ FormatStyle MergeStaticInlineOnly = getLLVMStyle();
+ MergeStaticInlineOn
@@ -335,6 +336,32 @@ class LineJoiner {
}
}
+ if (Style.AllowShortFunctionsOnASingleLine ==
+ FormatStyle::SFS_StaticInlineOnly ||
+ Style.AllowShortFunctionsOnASingleLine ==
+ FormatStyle::SFS_StaticInline) {
+// C
@@ -335,6 +336,32 @@ class LineJoiner {
}
}
+ if (Style.AllowShortFunctionsOnASingleLine ==
+ FormatStyle::SFS_StaticInlineOnly ||
+ Style.AllowShortFunctionsOnASingleLine ==
+ FormatStyle::SFS_StaticInline) {
+// C
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/131605
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks edited
https://github.com/llvm/llvm-project/pull/131605
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -5347,6 +5386,7 @@ struct FormatStyle {
InsertBraces == R.InsertBraces &&
InsertNewlineAtEOF == R.InsertNewlineAtEOF &&
IntegerLiteralSeparator == R.IntegerLiteralSeparator &&
+ KeywordedFunctionLikeMacros == R.KeywordedFunctionLike
https://github.com/HazardyKnusperkeks commented:
Nearly done. ;)
https://github.com/llvm/llvm-project/pull/131605
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -3276,6 +3276,45 @@ struct FormatStyle {
/// \version 20
bool KeepFormFeed;
+ /// Function-like declaration with keyworded parameters.
+ /// Lists possible keywords for a named function-like macro.
+ struct KeywordedFunctionLikeMacro {
+std::string Name;
+std
HazardyKnusperkeks wrote:
Please recheck all your added comments, if the wording is still the best one,
after renaming the option.
https://github.com/llvm/llvm-project/pull/131605
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.l
@@ -3146,6 +3146,45 @@ struct FormatStyle {
/// \version 16
IntegerLiteralSeparatorStyle IntegerLiteralSeparator;
+ /// Function-like declaration with keyworded parameters.
+ /// Lists possible keywords for a named macro-like function
HazardyKnusperkeks
@@ -3146,6 +3146,45 @@ struct FormatStyle {
/// \version 16
IntegerLiteralSeparatorStyle IntegerLiteralSeparator;
+ /// Function-like declaration with keyworded parameters.
+ /// Lists possible keywords for a named macro-like function
+ struct KeywordedFunctionLikeMacro
@@ -29102,6 +29102,65 @@ TEST_F(FormatTest, BreakBeforeClassName) {
"ArenaSafeUniquePtr {};");
}
+TEST_F(FormatTest, FunctionDeclarationWithKeywords) {
HazardyKnusperkeks wrote:
The test name should be changed, I'd refer directly to the opt
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/133033
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/133033
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/132941
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -720,8 +720,9 @@ TEST_F(TokenAnnotatorTest,
UnderstandsNonTemplateAngleBrackets) {
Tokens = annotate("return A < B != A > B;");
ASSERT_EQ(Tokens.size(), 10u) << Tokens;
- EXPECT_TOKEN(Tokens[2], tok::less, TT_BinaryOperator);
- EXPECT_TOKEN(Tokens[6], tok::greater, T
@@ -1,3 +1,4 @@
Strings
+FunctionDeclarationWithKeywordes
HazardyKnusperkeks wrote:
Then I'd say we change that. I mean this is the fourth entry to the file and
apparently it does not match.
https://github.com/llvm/llvm-project/pull/131605
@@ -1,3 +1,4 @@
Strings
+FunctionDeclarationWithKeywordes
HazardyKnusperkeks wrote:
I think you only need to fix this one?
https://github.com/llvm/llvm-project/pull/131605
___
cfe-commits mailing list
cfe-commits@list
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/132042
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -148,6 +160,24 @@ class AnnotatingParser {
}
}
+ const FormatStyle::FunctionDeclarationWithKeywords *
+ isInsideFunctionWithKeywordedParameters(const FormatToken &Token) const {
+const FormatToken *Previous = &Token;
+while (auto Prev = Previous->getPrevious
@@ -29096,6 +29096,63 @@ TEST_F(FormatTest, BreakBeforeClassName) {
"ArenaSafeUniquePtr {};");
}
+TEST_F(FormatTest, FunctionDeclarationWithKeywords) {
+ FormatStyle::FunctionDeclarationWithKeywords QPropertyDeclaration;
+ QPropertyDeclaration.Name = "Q_PR
@@ -2382,14 +2382,20 @@ size_t SourceManager::getDataStructureSizes() const {
SourceManagerForFile::SourceManagerForFile(StringRef FileName,
StringRef Content) {
+ // We copy to `std::string` for Context instead of StringRef because
https://github.com/HazardyKnusperkeks requested changes to this pull request.
You need to add a parsing test for your option and annotation tests for the
annotation.
https://github.com/llvm/llvm-project/pull/131605
___
cfe-commits mailing list
cfe-com
@@ -148,6 +160,24 @@ class AnnotatingParser {
}
}
+ const FormatStyle::FunctionDeclarationWithKeywords *
+ isInsideFunctionWithKeywordedParameters(const FormatToken &Token) const {
+const FormatToken *Previous = &Token;
+while (auto Prev = Previous->getPrevious
https://github.com/HazardyKnusperkeks edited
https://github.com/llvm/llvm-project/pull/131605
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -82,6 +82,7 @@ namespace format {
TYPE(FunctionAnnotationRParen)
\
TYPE(FunctionDeclarationName)
\
TYPE(FunctionDeclarationLParen)
@@ -1192,6 +1201,8 @@ template <> struct MappingTraits {
Style.WhitespaceSensitiveMacros);
IO.mapOptional("WrapNamespaceBodyWithEmptyLines",
Style.WrapNamespaceBodyWithEmptyLines);
+IO.mapOptional("FunctionDeclarationsWithKeywords",
@@ -5247,6 +5247,41 @@ struct FormatStyle {
/// \version 20
WrapNamespaceBodyWithEmptyLinesStyle WrapNamespaceBodyWithEmptyLines;
+ struct FunctionDeclarationWithKeywords {
+std::string Name;
+std::vector Keywords;
+
+bool operator==(const FunctionDeclarationW
@@ -2382,14 +2382,20 @@ size_t SourceManager::getDataStructureSizes() const {
SourceManagerForFile::SourceManagerForFile(StringRef FileName,
StringRef Content) {
+ // We copy to `std::string` for Context instead of StringRef because
@@ -148,6 +160,24 @@ class AnnotatingParser {
}
}
+ const FormatStyle::FunctionDeclarationWithKeywords *
+ isInsideFunctionWithKeywordedParameters(const FormatToken &Token) const {
+const FormatToken *Previous = &Token;
+while (auto Prev = Previous->getPrevious
@@ -349,6 +349,10 @@ bool ContinuationIndenter::canBreak(const LineState
&State) {
}
}
+ // Don't break between function parameter keywords and parameter names
HazardyKnusperkeks wrote:
```suggestion
// Don't break between function parameter keyword
@@ -116,6 +116,18 @@ static bool isCppAttribute(bool IsCpp, const FormatToken
&Tok) {
return AttrTok && AttrTok->startsSequence(tok::r_square, tok::r_square);
}
+static bool isParametersKeyword(
+const FormatToken &Tok,
+const FormatStyle::FunctionDeclarationWithKey
@@ -5435,7 +5470,10 @@ struct FormatStyle {
VerilogBreakBetweenInstancePorts ==
R.VerilogBreakBetweenInstancePorts &&
WhitespaceSensitiveMacros == R.WhitespaceSensitiveMacros &&
- WrapNamespaceBodyWithEmptyLines ==
R.WrapNamespace
@@ -148,6 +160,24 @@ class AnnotatingParser {
}
}
+ const FormatStyle::FunctionDeclarationWithKeywords *
+ isInsideFunctionWithKeywordedParameters(const FormatToken &Token) const {
+const FormatToken *Previous = &Token;
+while (auto Prev = Previous->getPrevious
@@ -148,6 +160,24 @@ class AnnotatingParser {
}
}
+ const FormatStyle::FunctionDeclarationWithKeywords *
+ isInsideFunctionWithKeywordedParameters(const FormatToken &Token) const {
+const FormatToken *Previous = &Token;
+while (auto Prev = Previous->getPrevious
@@ -148,6 +160,24 @@ class AnnotatingParser {
}
}
+ const FormatStyle::FunctionDeclarationWithKeywords *
+ isInsideFunctionWithKeywordedParameters(const FormatToken &Token) const {
HazardyKnusperkeks wrote:
The name is misleading, I'd expect a `bool`e
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/131434
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
HazardyKnusperkeks wrote:
I still think Google should have to say what their style in clang-format is,
extending to the default values of `AttributeMacros`.
I also wouldn't have such a big issue with adding it to the base style, because
of the prefix and I think it's nice that Boost or Qt most
@@ -3856,6 +3856,59 @@ TEST_F(TokenAnnotatorTest, AfterPPDirective) {
EXPECT_TOKEN(Tokens[2], tok::minusminus, TT_AfterPPDirective);
}
+TEST_F(TokenAnnotatorTest, UserDefinedConversionFunction) {
+ auto Tokens = annotate("operator int();");
+ ASSERT_EQ(Tokens.size(), 6u) <
@@ -1639,6 +1639,25 @@ class AnnotatingParser {
case tok::kw_operator:
if (Style.isProto())
break;
+ // C++ user-defined conversion function.
+ if (IsCpp && CurrentToken &&
+ (CurrentToken->is(tok::kw_auto) ||
+ CurrentToken->isTyp
@@ -2031,6 +2031,7 @@ class SourceManagerForFile {
// The order of these fields are important - they should be in the same order
// as they are created in `createSourceManagerForFile` so that they can be
// deleted in the reverse order as they are created.
+ std::string
@@ -2382,14 +2382,20 @@ size_t SourceManager::getDataStructureSizes() const {
SourceManagerForFile::SourceManagerForFile(StringRef FileName,
StringRef Content) {
+ // We copy to `std::string` for Context instead of StringRef because
@@ -29096,6 +29096,17 @@ TEST_F(FormatTest, BreakBeforeClassName) {
"ArenaSafeUniquePtr {};");
}
+TEST_F(FormatTest, DoesNotCrashOnNonNullTerminatedStringRefs) {
+ llvm::StringRef TwoLines = "namespace foo {}\n"
+ "namespace bar
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/130471
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/129983
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -5091,8 +5091,10 @@ UnwrappedLineParser::parseMacroCall() {
void UnwrappedLineParser::pushToken(FormatToken *Tok) {
Line->Tokens.push_back(UnwrappedLineNode(Tok));
if (MustBreakBeforeNextToken) {
HazardyKnusperkeks wrote:
Good.
https://github.com/llvm/
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/128988
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1441,8 +1441,9 @@ TEST(ConfigParseTest, GetStyleOfFile) {
ASSERT_EQ(*Style9, SubSubStyle);
// Test 9.8: use inheritance from a file without BasedOnStyle
- ASSERT_TRUE(FS.addFile("/e/withoutbase/.clang-format", 0,
- llvm::MemoryBuffer::getMemBuf
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/128817
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/128410
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/128623
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/128287
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -3353,7 +3353,12 @@ struct FormatStyle {
}
bool isTableGen() const { return Language == LK_TableGen; }
- /// Language, this format style is targeted at.
+ /// The language that this format style targets.
+ /// \note
+ /// You can also specify the language (``Cpp``
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/127964
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/127545
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/127306
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/127159
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1596,7 +1596,7 @@ static auto computeNewlines(const AnnotatedLine &Line,
if (Line.startsWith(TT_NamespaceRBrace)) {
if (Style.WrapNamespaceBodyWithEmptyLines == FormatStyle::WNBWELS_Never)
Newlines = 1;
- else if (!PreviousLine->startsWith(TT_Namespac
HazardyKnusperkeks wrote:
Was there a change which I should look at again? I find the GitHub UI for
reviews terrible. If it was just a rebase my vote stands.
https://github.com/llvm/llvm-project/pull/108332
___
cfe-commits mailing list
cfe-commits@lis
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/126340
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -260,15 +265,13 @@ def main():
"Ignoring the following files (wrong extension, symlink, or "
"ignored by clang-format):"
)
-for filename in ignored_files:
-print("%s" % filename)
+print_f
@@ -412,6 +414,15 @@ const FormatToken
*LeftRightQualifierAlignmentFixer::analyzeLeft(
// The case `const long long volatile int` -> `const volatile long long int`
// The case `long volatile long int const` -> `const volatile long long int`
if (TypeToken->isTypeName(Lang
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/125327
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
HazardyKnusperkeks wrote:
> > Seems to also work for top-level types (`::int_64_t constexpr x{123};`
> > works correctly) but breaks for fully qualified types (`::std::int64_t
> > constexpr x{123};` becomes `::constexpr std::int64_t x{123};`)
>
> Yeah, I intentionally didn't want to use a loop
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/125326
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -1169,6 +1181,18 @@ template <> struct MappingTraits {
IO.mapOptional("WhitespaceSensitiveMacros",
Style.WhitespaceSensitiveMacros);
+// If AlignAfterOpenBracket was specified but AlignAfterOpenBracketBreak
+// was not, initialize the latter f
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/124891
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/108332
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
HazardyKnusperkeks wrote:
> (Why drop the formatting test? Seems good to have an integration test for
> this, no?)
Because the bug was a misannotation. The formatting, based on the annotations,
should already be covered. Of course one can always add more tests, and I'm not
demanding to remove
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/124397
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request.
https://github.com/llvm/llvm-project/pull/124380
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -205,6 +205,12 @@ def main():
"commits"
),
)
+p.add_argument(
+"-0",
+"--null",
+action="store_true",
+help="print the affected paths with null-terminated characters",
HazardyKnusperkeks wrote:
I t
1 - 100 of 894 matches
Mail list logo