Skip to content
This repository has been archived by the owner on Jul 13, 2019. It is now read-only.

Commit

Permalink
Merge pull request #15 from tkruse/doxygen
Browse files Browse the repository at this point in the history
Doxygen
  • Loading branch information
tkruse committed Apr 24, 2016
2 parents c758498 + 534b218 commit a7c23c5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cpplint.py
Original file line number Diff line number Diff line change
Expand Up @@ -4474,9 +4474,13 @@ def CheckStyle(filename, clean_lines, linenum, file_extension, nesting_state,
#
# The "$Id:...$" comment may also get very long without it being the
# developers fault.
#
# Doxygen documentation copying can get pretty long when using an overloaded
# function declaration
if (not line.startswith('#include') and not is_header_guard and
not Match(r'^\s*//.*http(s?)://\S*$', line) and
not Match(r'^// \$Id:.*#[0-9]+ \$$', line)):
not Match(r'^// \$Id:.*#[0-9]+ \$$', line) and
not Match(r'^\s*/// [@\\](copydoc|copydetails|copybrief) .*$', line)):
line_width = GetLineWidth(line)
extended_length = int((_line_length * 1.25))
if line_width > extended_length:
Expand Down
9 changes: 9 additions & 0 deletions cpplint_unittest.py
Original file line number Diff line number Diff line change
Expand Up @@ -428,6 +428,15 @@ def testLineLengthCheck(self):
'static const char kL' + ('o' * 50) + 'ngIdentifier[] = R"()";\n',
'Lines should be <= 80 characters long'
' [whitespace/line_length] [2]')
self.TestLint(
' /// @copydoc ' + ('o' * (cpplint._line_length * 2)),
'')
self.TestLint(
' /// @copydetails ' + ('o' * (cpplint._line_length * 2)),
'')
self.TestLint(
' /// @copybrief ' + ('o' * (cpplint._line_length * 2)),
'')

# Test error suppression annotations.
def testErrorSuppression(self):
Expand Down

0 comments on commit a7c23c5

Please sign in to comment.