Do not detect macros like VIM_TRUE as boolean values

This commit is contained in:
ZyX 2014-05-02 16:06:30 +04:00 committed by Justin M. Keyes
parent 8a729897f4
commit 37935130f9

View File

@ -2802,7 +2802,7 @@ def CheckLanguage(filename, clean_lines, linenum, file_extension,
"('k' followed by CamelCase) compile-time constant for the size.")
# Detect TRUE and FALSE.
match = Search(r'(TRUE|FALSE)', line)
match = Search(r'\b(TRUE|FALSE)\b', line)
if match:
token = match.group(1)
error(filename, linenum, 'readability/bool', 4,