Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(105)

Unified Diff: presubmit_canned_checks.py

Issue 1034523003: Fine tune const NSClass* presubmit check (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: Split regex line Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: presubmit_canned_checks.py
diff --git a/presubmit_canned_checks.py b/presubmit_canned_checks.py
index 27cbc429542baed291000c7754d3bbd3041d6406..49ed07c6f853592116aba2a1366cc4b3ec6c61ee 100644
--- a/presubmit_canned_checks.py
+++ b/presubmit_canned_checks.py
@@ -948,7 +948,8 @@ def _RietveldOwnerAndReviewers(input_api, email_regexp, approval_needed=False):
def _CheckConstNSObject(input_api, output_api, source_file_filter):
"""Checks to make sure no objective-c files have |const NSSomeClass*|."""
pattern = input_api.re.compile(
- r'const\s+NS(?!(Point|Range|Rect|Size)\s*\*)\w*\s*\*')
+ r'(?<!reinterpret_cast<)'
+ r'const\s+NS(?!(Point|Range|Rect|Size)\s*\*)\w*\s*\*')
def objective_c_filter(f):
return (source_file_filter(f) and
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698