Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp4788088iob; Mon, 9 May 2022 01:26:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwldtnahp2HHbVZ9XZpW0DwKxlcOcU/hAGYg1nvl/OCKJ2aRI+ELjw/ku9W8cxYlZG4vgqJ X-Received: by 2002:a05:6a00:2188:b0:50d:b093:12a2 with SMTP id h8-20020a056a00218800b0050db09312a2mr14943072pfi.84.1652084775991; Mon, 09 May 2022 01:26:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652084775; cv=none; d=google.com; s=arc-20160816; b=NmeUc8DizhqVLWg8vXB5rwfirOs3amdsD08nP5R2fVM6d8TbvRZnexgr6d7XaeddkG sHzxsnlg36jXzLkUk5PuA7A8FGNFMmairRfLgBNE0zffWBHQv8r10dWnMSuHGfUkECQ/ rwIPYzUpH5HYEPcQe4FtThNePb7hxVwxmOp2s95FRDRkJg+uCt6e038tUsodVzbxOIpn psX1AsBrCBFBB6GQYsfdnFmj9ycXbfZBTyzn8wMm1bVO2qvJn3I3tXiRF2gNEPA13qCZ lyNnFzoshKBdMjSefWEaNQ34bp5uhYI3ZGmoMB7rAZ7rxX/bSReerVE64uv2KMclcY11 G4XQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=XPrrOfyJbh+OEbY3glq2iAPIyh71zckvQQZ9eI9pc7w=; b=ezNS/mnozNr52Gdn8IC26fYLK2ccono1lTBm62b/ziTUJ46Kbz4KyyITRmcbaKGfIb 4wEX24IO8B8qsZZt6U/+9lRd2gCEDERQ2G1834hee0mKHjrZIAWFg2wK8d71Mgc4O7EB FpuY3qy+2T8EqsWUYOo5xy3/FaGB/eUVX3uZiiTy7uZwr29SUnpAen9qMs+w6SjMV2q5 GsDeBq9kBbyjpvNhr4zRW5P1z39N/jC0ELDKffXkros/L/cLTNnxuszhm3RxkDCWjpy7 leSJfN/6O/h7rMfr29ViYX5aaWxu1mbLbUEDHQfjls/dNgyNpN8HQcxIoPE8K636PP0C hdyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@digikod.net header.s=20191114 header.b="mlLGK/j5"; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id k14-20020aa7820e000000b0050a99acc9ecsi12166541pfi.45.2022.05.09.01.26.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 May 2022 01:26:15 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@digikod.net header.s=20191114 header.b="mlLGK/j5"; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id EC0DF140C6E; Mon, 9 May 2022 01:11:45 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1443288AbiEFQDx (ORCPT + 99 others); Fri, 6 May 2022 12:03:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33730 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348385AbiEFQDf (ORCPT ); Fri, 6 May 2022 12:03:35 -0400 Received: from smtp-bc0e.mail.infomaniak.ch (smtp-bc0e.mail.infomaniak.ch [IPv6:2001:1600:4:17::bc0e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1B4B36D4D9 for ; Fri, 6 May 2022 08:59:51 -0700 (PDT) Received: from smtp-3-0000.mail.infomaniak.ch (unknown [10.4.36.107]) by smtp-3-3000.mail.infomaniak.ch (Postfix) with ESMTPS id 4KvwHn3VZxzMq1PY; Fri, 6 May 2022 17:59:49 +0200 (CEST) Received: from localhost (unknown [23.97.221.149]) by smtp-3-0000.mail.infomaniak.ch (Postfix) with ESMTPA id 4KvwHn1QqRzlhRVT; Fri, 6 May 2022 17:59:49 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=digikod.net; s=20191114; t=1651852789; bh=5yiUmrh6mlYQh3DCfa434DsRAxQHhOjF2SlkOyGu7nQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=mlLGK/j5Q05j0Zba83UJpnk9EeC64v9Hcgx5VPTsXhDL8JgYqxcuFGQgy+Rn8u54O dX8jlQAZpYz5PlnejXbT+Tftdw0lkWcQ/Ljn8d/nYgOJKWKsi5nx4CjD8b+V//F6Js AjVIqlagBiopynuqfBu7rWFUPsxiT0J9otE2CAog= From: =?UTF-8?q?Micka=C3=ABl=20Sala=C3=BCn?= To: Miguel Ojeda Cc: =?UTF-8?q?Micka=C3=ABl=20Sala=C3=BCn?= , Andy Whitcroft , Brian Norris , Dwaipayan Ray , "Jason A . Donenfeld" , Joe Perches , Kees Cook , Konstantin Meskhidze , Lukas Bulwahn , Nathan Chancellor , Nick Desaulniers , Paul Moore , Tom Rix , linux-kernel@vger.kernel.org, llvm@lists.linux.dev Subject: [PATCH v2 2/5] clang-format: Update to clang-format >= 6 Date: Fri, 6 May 2022 18:01:03 +0200 Message-Id: <20220506160106.522341-3-mic@digikod.net> In-Reply-To: <20220506160106.522341-1-mic@digikod.net> References: <20220506160106.522341-1-mic@digikod.net> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We get new interesting formating with clang-format greater or equal to 6 as stated in the removed comments. Miguel Ojeda suggested to even move the minimal clang-format version to 11, which is the minimum LLVM supported at the moment [1]. Automatically updated with: sed -i 's/^\(\s*\)#\(\S*\s\+\S*\) # Unknown to clang-format.*/\1\2/' .clang-format Link: https://lore.kernel.org/r/CANiq72nLOfmEt-CZBmm2ouEB_x6Jm9ggDVFCVJxYxKw7O0LTzQ@mail.gmail.com [1] Cc: Miguel Ojeda Cc: Tom Rix Signed-off-by: Mickaël Salaün Link: https://lore.kernel.org/r/20220506160106.522341-3-mic@digikod.net --- Changes since v1: * Update documentation header with clang-format >= 6. --- .clang-format | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/.clang-format b/.clang-format index 70d4e7ec4cf9..3bc1bdf0f3a1 100644 --- a/.clang-format +++ b/.clang-format @@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0 # -# clang-format configuration file. Intended for clang-format >= 4. +# clang-format configuration file. Intended for clang-format >= 6. # # For more information, see: # @@ -13,7 +13,7 @@ AccessModifierOffset: -4 AlignAfterOpenBracket: Align AlignConsecutiveAssignments: false AlignConsecutiveDeclarations: false -#AlignEscapedNewlines: Left # Unknown to clang-format-4.0 +AlignEscapedNewlines: Left AlignOperands: true AlignTrailingComments: false AllowAllParametersOfDeclarationOnNextLine: false @@ -37,24 +37,24 @@ BraceWrapping: AfterObjCDeclaration: false AfterStruct: false AfterUnion: false - #AfterExternBlock: false # Unknown to clang-format-5.0 + AfterExternBlock: false BeforeCatch: false BeforeElse: false IndentBraces: false - #SplitEmptyFunction: true # Unknown to clang-format-4.0 - #SplitEmptyRecord: true # Unknown to clang-format-4.0 - #SplitEmptyNamespace: true # Unknown to clang-format-4.0 + SplitEmptyFunction: true + SplitEmptyRecord: true + SplitEmptyNamespace: true BreakBeforeBinaryOperators: None BreakBeforeBraces: Custom -#BreakBeforeInheritanceComma: false # Unknown to clang-format-4.0 +BreakBeforeInheritanceComma: false BreakBeforeTernaryOperators: false BreakConstructorInitializersBeforeComma: false -#BreakConstructorInitializers: BeforeComma # Unknown to clang-format-4.0 +BreakConstructorInitializers: BeforeComma BreakAfterJavaFieldAnnotations: false BreakStringLiterals: false ColumnLimit: 80 CommentPragmas: '^ IWYU pragma:' -#CompactNamespaces: false # Unknown to clang-format-4.0 +CompactNamespaces: false ConstructorInitializerAllOnOneLineOrOnePerLine: false ConstructorInitializerIndentWidth: 8 ContinuationIndentWidth: 8 @@ -62,7 +62,7 @@ Cpp11BracedListStyle: false DerivePointerAlignment: false DisableFormat: false ExperimentalAutoDetectBinPacking: false -#FixNamespaceComments: false # Unknown to clang-format-4.0 +FixNamespaceComments: false # Taken from: # git grep -h '^#define [^[:space:]]*for_each[^[:space:]]*(' include/ tools/ \ @@ -627,13 +627,13 @@ ForEachMacros: - 'xbc_node_for_each_subkey' - 'zorro_for_each_dev' -#IncludeBlocks: Preserve # Unknown to clang-format-5.0 +IncludeBlocks: Preserve IncludeCategories: - Regex: '.*' Priority: 1 IncludeIsMainRegex: '(Test)?$' IndentCaseLabels: false -#IndentPPDirectives: None # Unknown to clang-format-5.0 +IndentPPDirectives: None IndentWidth: 8 IndentWrappedFunctionNames: false JavaScriptQuotes: Leave @@ -643,13 +643,13 @@ MacroBlockBegin: '' MacroBlockEnd: '' MaxEmptyLinesToKeep: 1 NamespaceIndentation: None -#ObjCBinPackProtocolList: Auto # Unknown to clang-format-5.0 +ObjCBinPackProtocolList: Auto ObjCBlockIndentWidth: 8 ObjCSpaceAfterProperty: true ObjCSpaceBeforeProtocolList: true # Taken from git's rules -#PenaltyBreakAssignment: 10 # Unknown to clang-format-4.0 +PenaltyBreakAssignment: 10 PenaltyBreakBeforeFirstCallParameter: 30 PenaltyBreakComment: 10 PenaltyBreakFirstLessLess: 0 @@ -660,14 +660,14 @@ PenaltyReturnTypeOnItsOwnLine: 60 PointerAlignment: Right ReflowComments: false SortIncludes: false -#SortUsingDeclarations: false # Unknown to clang-format-4.0 +SortUsingDeclarations: false SpaceAfterCStyleCast: false SpaceAfterTemplateKeyword: true SpaceBeforeAssignmentOperators: true -#SpaceBeforeCtorInitializerColon: true # Unknown to clang-format-5.0 -#SpaceBeforeInheritanceColon: true # Unknown to clang-format-5.0 +SpaceBeforeCtorInitializerColon: true +SpaceBeforeInheritanceColon: true SpaceBeforeParens: ControlStatements -#SpaceBeforeRangeBasedForLoopColon: true # Unknown to clang-format-5.0 +SpaceBeforeRangeBasedForLoopColon: true SpaceInEmptyParentheses: false SpacesBeforeTrailingComments: 1 SpacesInAngles: false -- 2.35.1