[prev in list] [next in list] [prev in thread] [next in thread] 

List:       cfe-dev
Subject:    [cfe-dev] [clang-tidy] Disabling checks for multiple lines
From:       Tobias Klinke via cfe-dev <cfe-dev () lists ! llvm ! org>
Date:       2019-11-21 18:24:48
Message-ID: 18d6e86b-c611-5aaa-0f4f-7ac5fb9f188c () die-klinkes ! de
[Download RAW message or body]

Hi,

currently there is no way to disable clang-tidy checks for a whole 
section of code inline in a similar way to // NOLINT for a single line.

I found two references where the topic has already been brought up:

- as a side topic in a review: https://reviews.llvm.org/D54757#1317477

- as a Bugzilla entry: https://bugs.llvm.org/show_bug.cgi?id=32222

Has anyone worked on this so far? I am willing to implement the feature 
and bring it upstream. Would such a patch be welcome?

For the syntax, I would use the proposed '// BEGINNOLINT // ENDNOLINT' 
with optional list of checks to disable/enable. However, I am open to 
other proposals.

Background: I'm currently introducing clang-tidy to a large embedded 
code base, where there are quite a few sections for which certain checks 
do not apply (platform specific, mixing C and C++, generated code etc.). 
It would be very convenient if this feature would be available to us.

Regards,

Tobias

_______________________________________________
cfe-dev mailing list
cfe-dev@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic