mirror of
https://github.com/isocpp/CppCoreGuidelines.git
synced 2025-12-17 12:44:42 +03:00
add "return" to the compound literal exclusions (#1113)
inhibits readability/brace warning for compound literals in return statement
This commit is contained in:
committed by
Andrew Pardoe
parent
999f9dd0ce
commit
9de66ec027
1
scripts/python/cpplint.py
vendored
1
scripts/python/cpplint.py
vendored
@@ -4091,6 +4091,7 @@ def CheckTrailingSemicolon(filename, clean_lines, linenum, error):
|
||||
(func and not Search(r'\boperator\s*\[\s*\]', func.group(1))) or
|
||||
Search(r'\b(?:struct|union)\s+alignas\s*$', line_prefix) or
|
||||
Search(r'\bdecltype$', line_prefix) or
|
||||
Search(r'\breturn\s*$', line_prefix) or
|
||||
Search(r'\s+=\s*$', line_prefix)):
|
||||
match = None
|
||||
if (match and
|
||||
|
||||
Reference in New Issue
Block a user