From e871d4e50abe9807384013af31904491ff34efcf Mon Sep 17 00:00:00 2001 From: sbiscigl Date: Tue, 1 Oct 2024 11:58:50 -0400 Subject: [PATCH] test clang-format --- .clang-format | 38 +------------------ .github/workflows/clang-format.yml | 2 +- .../include/aws/core/client/AWSClient.h | 1 + .../source/client/AWSClient.cpp | 4 +- 4 files changed, 6 insertions(+), 39 deletions(-) diff --git a/.clang-format b/.clang-format index 7403b0f07fc..d69b351727b 100644 --- a/.clang-format +++ b/.clang-format @@ -4,34 +4,6 @@ Language: Cpp AccessModifierOffset: -1 AlignAfterOpenBracket: Align AlignArrayOfStructures: None -AlignConsecutiveAssignments: - Enabled: false - AcrossEmptyLines: false - AcrossComments: false - AlignCompound: false - AlignFunctionPointers: false - PadOperators: true -AlignConsecutiveBitFields: - Enabled: false - AcrossEmptyLines: false - AcrossComments: false - AlignCompound: false - AlignFunctionPointers: false - PadOperators: false -AlignConsecutiveDeclarations: - Enabled: false - AcrossEmptyLines: false - AcrossComments: false - AlignCompound: false - AlignFunctionPointers: false - PadOperators: false -AlignConsecutiveMacros: - Enabled: false - AcrossEmptyLines: false - AcrossComments: false - AlignCompound: false - AlignFunctionPointers: false - PadOperators: false AlignConsecutiveShortCaseStatements: Enabled: false AcrossEmptyLines: false @@ -39,9 +11,6 @@ AlignConsecutiveShortCaseStatements: AlignCaseColons: false AlignEscapedNewlines: Left AlignOperands: Align -AlignTrailingComments: - Kind: Always - OverEmptyLines: 0 AllowAllArgumentsOnNextLine: true AllowAllParametersOfDeclarationOnNextLine: true AllowBreakBeforeNoexceptSpecifier: Never @@ -86,7 +55,6 @@ BreakAfterAttributes: Leave BreakAfterJavaFieldAnnotations: false BreakArrays: true BreakBeforeBinaryOperators: None -BreakBeforeConceptDeclarations: Always BreakBeforeBraces: Attach BreakBeforeInlineASMColon: OnlyMultiline BreakBeforeTernaryOperators: true @@ -219,10 +187,9 @@ RequiresClausePosition: OwnLine RequiresExpressionIndentation: OuterScope SeparateDefinitionBlocks: Leave ShortNamespaceLines: 1 -SkipMacroDefinitionBody: false SortIncludes: CaseSensitive SortJavaStaticImport: Before -SortUsingDeclarations: LexicographicNumeric +SortUsingDeclarations: true SpaceAfterCStyleCast: false SpaceAfterLogicalNot: false SpaceAfterTemplateKeyword: true @@ -241,9 +208,6 @@ SpaceBeforeParensOptions: AfterFunctionDeclarationName: false AfterIfMacros: true AfterOverloadedOperator: false - AfterPlacementOperator: true - AfterRequiresInClause: false - AfterRequiresInExpression: false BeforeNonEmptyParentheses: false SpaceBeforeRangeBasedForLoopColon: true SpaceBeforeSquareBrackets: false diff --git a/.github/workflows/clang-format.yml b/.github/workflows/clang-format.yml index 5128d500ea1..f0066750500 100644 --- a/.github/workflows/clang-format.yml +++ b/.github/workflows/clang-format.yml @@ -9,4 +9,4 @@ jobs: - name: clang format diff check run: | git fetch origin main - git clang-format-15 --help \ No newline at end of file + git clang-format-15 origin/main --diff \ No newline at end of file diff --git a/src/aws-cpp-sdk-core/include/aws/core/client/AWSClient.h b/src/aws-cpp-sdk-core/include/aws/core/client/AWSClient.h index 19bf979d7d5..b694a47bd35 100644 --- a/src/aws-cpp-sdk-core/include/aws/core/client/AWSClient.h +++ b/src/aws-cpp-sdk-core/include/aws/core/client/AWSClient.h @@ -358,6 +358,7 @@ namespace Aws void AppendHeaderValueToRequest( const std::shared_ptr &request, String header, String value) const; + void SomePoorlyFormattedFunction(const Aws::String&arg,const Aws::String&anotherarg, const Aws::String&anotheranotherarg, const Aws::String&anotheranotheranotherarg); }; AWS_CORE_API Aws::String GetAuthorizationHeader(const Aws::Http::HttpRequest& httpRequest); diff --git a/src/aws-cpp-sdk-core/source/client/AWSClient.cpp b/src/aws-cpp-sdk-core/source/client/AWSClient.cpp index f7b728b134c..90c8e27516c 100644 --- a/src/aws-cpp-sdk-core/source/client/AWSClient.cpp +++ b/src/aws-cpp-sdk-core/source/client/AWSClient.cpp @@ -796,8 +796,10 @@ void AWSClient::AppendHeaderValueToRequest(const std::shared_ptr& httpRequest, - const Aws::AmazonWebServiceRequest& request) const + const Aws::AmazonWebServiceRequest& request) const { Aws::String checksumAlgorithmName = Aws::Utils::StringUtils::ToLower(request.GetChecksumAlgorithmName().c_str()); if (request.GetServiceSpecificParameters()) {