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

Unified Diff: cc/PRESUBMIT.py

Issue 657103003: cc: Change scoped_ptr<T>() to nullptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 | cc/animation/keyframed_animation_curve_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/PRESUBMIT.py
diff --git a/cc/PRESUBMIT.py b/cc/PRESUBMIT.py
index 6dff3716798daa8bc6bf629f08c0763860055755..9eac935598aeb9efd3fc7e5df6e49f2eea207d40 100644
--- a/cc/PRESUBMIT.py
+++ b/cc/PRESUBMIT.py
@@ -170,9 +170,8 @@ def CheckScopedPtr(input_api, output_api,
('%s:%d uses explicit scoped_ptr constructor. ' +
'Use make_scoped_ptr() instead.') % (f.LocalPath(), line_number)))
# Disallow:
- # return scoped_ptr<T>();
- # bar = scoped_ptr<T>();
- if re.search(r'(=|\breturn)\s*scoped_ptr<.*?>\(\)', line):
+ # scoped_ptr<T>()
+ if re.search(r'\bscoped_ptr<.*?>\(\)', line):
errors.append(output_api.PresubmitError(
'%s:%d uses scoped_ptr<T>(). Use nullptr instead.' %
(f.LocalPath(), line_number)))
« no previous file with comments | « no previous file | cc/animation/keyframed_animation_curve_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698