From dd7854c52f4ded7f8c7f7f2debf7186e7102a14f Mon Sep 17 00:00:00 2001 From: Jeff Donahue Date: Tue, 25 Feb 2014 12:00:41 -0800 Subject: suppress linter errors due to not including the directory when naming .h files --- scripts/cpplint.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/cpplint.py b/scripts/cpplint.py index 76d07352..52eb2230 100755 --- a/scripts/cpplint.py +++ b/scripts/cpplint.py @@ -148,6 +148,7 @@ _ERROR_CATEGORIES = [ 'build/header_guard', 'build/include', 'build/include_alpha', + 'build/include_dir', 'build/include_order', 'build/include_what_you_use', 'build/namespaces', @@ -207,7 +208,7 @@ _ERROR_CATEGORIES = [ # flag. By default all errors are on, so only add here categories that should be # off by default (i.e., categories that must be enabled by the --filter= flags). # All entries here should start with a '-' or '+', as in the --filter= flag. -_DEFAULT_FILTERS = ['-build/include_alpha'] +_DEFAULT_FILTERS = ['-build/include_alpha', '-build/include_dir'] # We used to check for high-bit characters, but after much discussion we # decided those were OK, as long as they were in UTF-8 and didn't represent @@ -3585,7 +3586,7 @@ def CheckIncludeLine(filename, clean_lines, linenum, include_state, error): # "include" should use the new style "foo/bar.h" instead of just "bar.h" if _RE_PATTERN_INCLUDE_NEW_STYLE.search(line): - error(filename, linenum, 'build/include', 4, + error(filename, linenum, 'build/include_dir', 4, 'Include the directory when naming .h files') # we shouldn't include a file more than once. actually, there are a -- cgit v1.2.3