From commits-return-8243-archive-asf-public=cust-asf.ponee.io@kudu.apache.org Thu Dec 5 07:04:40 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 5803218065B for ; Thu, 5 Dec 2019 08:04:40 +0100 (CET) Received: (qmail 20630 invoked by uid 500); 5 Dec 2019 07:04:39 -0000 Mailing-List: contact commits-help@kudu.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@kudu.apache.org Delivered-To: mailing list commits@kudu.apache.org Received: (qmail 20609 invoked by uid 99); 5 Dec 2019 07:04:39 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 05 Dec 2019 07:04:39 +0000 Received: by gitbox.apache.org (ASF Mail Server at gitbox.apache.org, from userid 33) id 20BF58D807; Thu, 5 Dec 2019 07:04:38 +0000 (UTC) Date: Thu, 05 Dec 2019 07:04:39 +0000 To: "commits@kudu.apache.org" Subject: [kudu] 01/03: clang_tidy_gerrit: disable llvm-include-order check MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit From: alexey@apache.org In-Reply-To: <157552947888.1998.7284505909863793163@gitbox.apache.org> References: <157552947888.1998.7284505909863793163@gitbox.apache.org> X-Git-Host: gitbox.apache.org X-Git-Repo: kudu X-Git-Refname: refs/heads/master X-Git-Reftype: branch X-Git-Rev: ddaf67d8b7a5f560fcd5645e14739da4ba478869 X-Git-NotificationType: diff X-Git-Multimail-Version: 1.5.dev Auto-Submitted: auto-generated Message-Id: <20191205070439.20BF58D807@gitbox.apache.org> This is an automated email from the ASF dual-hosted git repository. alexey pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/kudu.git commit ddaf67d8b7a5f560fcd5645e14739da4ba478869 Author: Alexey Serbin AuthorDate: Wed Dec 4 15:39:39 2019 -0800 clang_tidy_gerrit: disable llvm-include-order check The 'llvm-include-order' check in clang-tidy contradicts with IWYU on the order of 'file.h' and 'file-inl.h' include file pairs. IWYU intentionally orders 'file-inl.h' and 'file.h' to make 'file.h' preceding it's 'file-inl.h' counterpart. To avoid confusion, let's isable the 'llvm-include-order' check. Change-Id: Ie1f0e3a5b8447940be74071cc6701ac5eb5ddcf6 Reviewed-on: http://gerrit.cloudera.org:8080/14839 Tested-by: Alexey Serbin Reviewed-by: Adar Dembo --- build-support/clang_tidy_gerrit.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/build-support/clang_tidy_gerrit.py b/build-support/clang_tidy_gerrit.py index 35b206a..cd500b1 100755 --- a/build-support/clang_tidy_gerrit.py +++ b/build-support/clang_tidy_gerrit.py @@ -49,6 +49,25 @@ DISABLED_TIDY_CHECKS=[ # Although useful in production code, we use magic numbers liberally in # tests, and many would be net less clear as named constants. 'readability-magic-numbers', + + # IWYU has specific rules for ordering '-inl.h' include files, i.e. + # 'header.h' and its 'header-inl.h' counterpart. It seems in some cases + # including 'header-inl.h' before 'header.h' might even lead to compilation + # failures. So, IWYU intentionally re-orders them even if 'header-inl.h' + # comes before 'header.h' lexicographically in default C locale: + # https://github.com/apache/kudu/blob/ \ + # 89ce529e945731c48445db4a6f8af11f9f905aab/build-support/iwyu/ \ + # fix_includes.py#L1786-L1787 + # + # That ordering contradicts with what clang-tidy recommends when using the + # 'llvm-include-order' check. To avoid confusion, let's disable the + # 'llvm-include-order'. + # + # TODO(aserbin): clarify whether it's possible to customize clang-tidy + # behavior w.r.t. the sorting of such header files using + # the format style options described at + # https://clang.llvm.org/docs/ClangFormatStyleOptions.html + 'llvm-include-order', ] def run_tidy(sha="HEAD", is_rev_range=False):