| Index: third_party/WebKit/Tools/Scripts/webkitpy/style/filter.py
|
| diff --git a/third_party/WebKit/Tools/Scripts/webkitpy/style/filter.py b/third_party/WebKit/Tools/Scripts/webkitpy/style/filter.py
|
| index 608a9e60c4f2bf6bd060a238dc2bb4adad3bbd22..33ef3bf9b7eb85a93f1ee911ba0212b5f2c2bc74 100644
|
| --- a/third_party/WebKit/Tools/Scripts/webkitpy/style/filter.py
|
| +++ b/third_party/WebKit/Tools/Scripts/webkitpy/style/filter.py
|
| @@ -76,7 +76,7 @@ class _CategoryFilter(object):
|
| filter_rules = []
|
|
|
| self._filter_rules = filter_rules
|
| - self._should_check_category = {} # Cached dictionary of category to True/False
|
| + self._should_check_category = {} # Cached dictionary of category to True/False
|
|
|
| def __str__(self):
|
| return ",".join(self._filter_rules)
|
| @@ -108,12 +108,12 @@ class _CategoryFilter(object):
|
| if category in self._should_check_category:
|
| return self._should_check_category[category]
|
|
|
| - should_check = True # All categories checked by default.
|
| + should_check = True # All categories checked by default.
|
| for rule in self._filter_rules:
|
| if not category.startswith(rule[1:]):
|
| continue
|
| should_check = rule.startswith('+')
|
| - self._should_check_category[category] = should_check # Update cache.
|
| + self._should_check_category[category] = should_check # Update cache.
|
| return should_check
|
|
|
|
|
| @@ -213,7 +213,7 @@ class FilterConfiguration(object):
|
| for sub_path in sub_paths:
|
| if path.find(sub_path) > -1:
|
| return tuple(path_rules)
|
| - return () # Default to the empty tuple.
|
| + return () # Default to the empty tuple.
|
|
|
| def _filter_from_path_rules(self, path_rules):
|
| """Return the CategoryFilter associated to the given path rules.
|
| @@ -227,7 +227,7 @@ class FilterConfiguration(object):
|
| # We reuse the same CategoryFilter where possible to take
|
| # advantage of the caching they do.
|
| if path_rules not in self._path_rules_to_filter:
|
| - rules = list(self._base_rules) # Make a copy
|
| + rules = list(self._base_rules) # Make a copy
|
| rules.extend(path_rules)
|
| rules.extend(self._user_rules)
|
| self._path_rules_to_filter[path_rules] = _CategoryFilter(rules)
|
| @@ -275,4 +275,3 @@ class FilterConfiguration(object):
|
|
|
| """
|
| return self._filter_from_path(path).should_check(category)
|
| -
|
|
|