From e0702ae16ad2bc0526cf9a987c0588e2d3603221 Mon Sep 17 00:00:00 2001 From: Akira Okumura Date: Mon, 21 Sep 2015 13:26:26 +0200 Subject: [PATCH] Add "typeid" in the exclusion list in CheckCStyleCast" --- cpplint/cpplint.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpplint/cpplint.py b/cpplint/cpplint.py index ccc25d4..22577ee 100755 --- a/cpplint/cpplint.py +++ b/cpplint/cpplint.py @@ -5357,7 +5357,7 @@ def CheckCStyleCast(filename, clean_lines, linenum, cast_type, pattern, error): # Exclude lines with keywords that tend to look like casts context = line[0:match.start(1) - 1] - if Match(r'.*\b(?:sizeof|alignof|alignas|[_A-Z][_A-Z0-9]*)\s*$', context): + if Match(r'.*\b(?:sizeof|typeid|alignof|alignas|[_A-Z][_A-Z0-9]*)\s*$', context): return False # Try expanding current context to see if we one level of