Create more targeted CPPLINT.cfg files.
This CL moves the filters out of the PRESUBMIT.py file and into specific folder CPPLINT.cfg files. This allows having all the lints enabled in the Tint code and specifically disabling in Dawn code as needed. Bug: dawn:1339 Change-Id: Ieb0178b0aac0ea67c52cc5547984ea5696eef5a4 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/86208 Auto-Submit: Dan Sinclair <dsinclair@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: Ben Clayton <bclayton@google.com>
This commit is contained in:
parent
cee1b54058
commit
fcf56791c1
11
PRESUBMIT.py
11
PRESUBMIT.py
|
@ -71,14 +71,7 @@ NONINCLUSIVE_REGEX_LIST = []
|
||||||
for reg in NONINCLUSIVE_REGEXES:
|
for reg in NONINCLUSIVE_REGEXES:
|
||||||
NONINCLUSIVE_REGEX_LIST.append(re.compile(reg))
|
NONINCLUSIVE_REGEX_LIST.append(re.compile(reg))
|
||||||
|
|
||||||
LINT_FILTERS = [
|
LINT_FILTERS = []
|
||||||
"-build/header_guard", "-build/include", "-build/include_directory",
|
|
||||||
"-build/include_order", "-build/include_what_you_use", "-build/namespaces",
|
|
||||||
"-legal/copyright", "-readability/braces", "-readability/casting",
|
|
||||||
"-readability/inheritance", "-readability/namespace", "-runtime/explicit",
|
|
||||||
"-runtime/indentation_namespace", "-runtime/int", "-runtime/printf",
|
|
||||||
"-whitespace/empty_if_body"
|
|
||||||
]
|
|
||||||
|
|
||||||
|
|
||||||
def _CheckNonInclusiveLanguage(input_api, output_api, source_file_filter=None):
|
def _CheckNonInclusiveLanguage(input_api, output_api, source_file_filter=None):
|
||||||
|
@ -97,7 +90,7 @@ def _CheckNonInclusiveLanguage(input_api, output_api, source_file_filter=None):
|
||||||
|
|
||||||
if len(matches):
|
if len(matches):
|
||||||
return [
|
return [
|
||||||
output_api.PresubmitPromptWarning('Non-inclusive language found:',
|
output_api.PresubmitPromptWarning("Non-inclusive language found:",
|
||||||
items=matches)
|
items=matches)
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
exclude_files=.*
|
|
@ -0,0 +1,5 @@
|
||||||
|
filter=-build/header_guard
|
||||||
|
filter=-build/include_order
|
||||||
|
filter=-readability/inheritance
|
||||||
|
filter=-runtime/explicit
|
||||||
|
filter=-runtime/indentation_namespace
|
|
@ -0,0 +1,2 @@
|
||||||
|
filter=-build/header_guard
|
||||||
|
filter=-legal/copyright
|
|
@ -0,0 +1,5 @@
|
||||||
|
filter=-build/header_guard
|
||||||
|
filter=-build/include
|
||||||
|
filter=-build/include_order
|
||||||
|
filter=-build/include_what_you_use
|
||||||
|
filter=-readability/casting
|
|
@ -0,0 +1,16 @@
|
||||||
|
filter=-build/header_guard
|
||||||
|
filter=-build/include
|
||||||
|
filter=-build/include_directory
|
||||||
|
filter=-build/include_order
|
||||||
|
filter=-build/include_what_you_use
|
||||||
|
filter=-build/namespaces
|
||||||
|
filter=-legal/copyright
|
||||||
|
filter=-readability/braces
|
||||||
|
filter=-readability/casting
|
||||||
|
filter=-readability/inheritance
|
||||||
|
filter=-readability/namespace
|
||||||
|
filter=-runtime/explicit
|
||||||
|
filter=-runtime/indentation_namespace
|
||||||
|
filter=-runtime/int
|
||||||
|
filter=-runtime/printf
|
||||||
|
filter=-whitespace/empty_if_body
|
|
@ -0,0 +1,2 @@
|
||||||
|
filter=-build/header_guard
|
||||||
|
filter=-legal/copyright
|
Loading…
Reference in New Issue