From 6aa026b289535c0c1aa411447cf575a7afc28620 Mon Sep 17 00:00:00 2001 From: Benjamin Kietzman Date: Tue, 1 Oct 2019 16:58:43 -0400 Subject: [PATCH] ignore alt_tokens when checking fncall spacing --- cpplint/cpplint.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cpplint/cpplint.py b/cpplint/cpplint.py index 65baa6c..fe5eba3 100755 --- a/cpplint/cpplint.py +++ b/cpplint/cpplint.py @@ -2992,6 +2992,8 @@ def CheckSpacingForFunctionCall(filename, clean_lines, linenum, error): not Search(r'_{0,2}asm_{0,2}\s+_{0,2}volatile_{0,2}\s+\(', fncall) and not Search(r'#\s*define|typedef|using\s+\w+\s*=', fncall) and not Search(r'\w\s+\((\w+::)*\*\w+\)\(', fncall) and + not Search(r'\b(' + '|'.join(_ALT_TOKEN_REPLACEMENT.keys()) + r')\b\s+\(', + fncall) and not Search(r'\bcase\s+\(', fncall)): # TODO(unknown): Space after an operator function seem to be a common # error, silence those for now by restricting them to highest verbosity.