mirror of
https://github.com/google/styleguide.git
synced 2024-03-22 13:11:43 +08:00
Add "typeid" in the exclusion list in CheckCStyleCast"
This commit is contained in:
parent
3591b2e540
commit
e0702ae16a
2
cpplint/cpplint.py
vendored
2
cpplint/cpplint.py
vendored
|
@ -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
|
||||
|
|
Loading…
Reference in New Issue
Block a user