Changeset 51541 in webkit


Ignore:
Timestamp:
Dec 1, 2009 8:46:48 AM (14 years ago)
Author:
abarth@webkit.org
Message:

2009-12-01 Adam Barth <abarth@webkit.org>

Reviewed by Eric Seidel.

check-webkit-style complains about #imports with / in them
https://bugs.webkit.org/show_bug.cgi?id=32022

We need to exclude #import directives in addition to #include from the
binary operator whitespace checks.

  • Scripts/modules/cpp_style.py:
  • Scripts/modules/cpp_style_unittest.py:
Location:
trunk/WebKitTools
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKitTools/ChangeLog

    r51526 r51541  
     12009-12-01  Adam Barth  <abarth@webkit.org>
     2
     3        Reviewed by Eric Seidel.
     4
     5        check-webkit-style complains about #imports with / in them
     6        https://bugs.webkit.org/show_bug.cgi?id=32022
     7
     8        We need to exclude #import directives in addition to #include from the
     9        binary operator whitespace checks.
     10
     11        * Scripts/modules/cpp_style.py:
     12        * Scripts/modules/cpp_style_unittest.py:
     13
    1142009-11-30  Adam Barth  <abarth@webkit.org>
    215
  • trunk/WebKitTools/Scripts/modules/cpp_style.py

    r51526 r51541  
    15341534    # Don't try to do spacing checks for operator methods
    15351535    line = re.sub(r'operator(==|!=|<|<<|<=|>=|>>|>)\(', 'operator\(', line)
    1536     # Don't try to do spacing checks for #include statements at minimum it
    1537     # messes up checks for spacing around /
    1538     if match(r'\s*#\s*include', line):
     1536    # Don't try to do spacing checks for #include or #import statements at
     1537    # minimum because it messes up checks for spacing around /
     1538    if match(r'\s*#\s*(?:include|import)', line):
    15391539        return
    15401540    if search(r'[\w.]=[\w.]', line):
  • trunk/WebKitTools/Scripts/modules/cpp_style_unittest.py

    r50091 r51541  
    12721272        self.assert_multi_line_lint('#include "config.h"\n#include <sys/io.h>\n',
    12731273                                    '')
     1274        self.assert_multi_line_lint('#include "config.h"\n#import <foo/bar.h>\n',
     1275                                    '')
    12741276
    12751277    def test_spacing_before_last_semicolon(self):
Note: See TracChangeset for help on using the changeset viewer.