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

Side by Side Diff: components/metrics/leak_detector/leak_detector.cc

Issue 2440303002: Remove usage of FOR_EACH_OBSERVER macro in components/ (Closed)
Patch Set: remove superfluous return Created 4 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « components/infobars/core/infobar_manager.cc ('k') | components/metrics/metrics_service.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/metrics/leak_detector/leak_detector.h" 5 #include "components/metrics/leak_detector/leak_detector.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 10
(...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after
340 340
341 if (!task_runner_->RunsTasksOnCurrentThread()) { 341 if (!task_runner_->RunsTasksOnCurrentThread()) {
342 task_runner_->PostTask(FROM_HERE, 342 task_runner_->PostTask(FROM_HERE,
343 base::Bind(&LeakDetector::NotifyObservers, 343 base::Bind(&LeakDetector::NotifyObservers,
344 base::Unretained(this), reports)); 344 base::Unretained(this), reports));
345 return; 345 return;
346 } 346 }
347 347
348 { 348 {
349 base::AutoLock lock(observers_lock_); 349 base::AutoLock lock(observers_lock_);
350 FOR_EACH_OBSERVER(Observer, observers_, OnLeaksFound(reports)); 350 for (Observer& observer : observers_)
351 observer.OnLeaksFound(reports);
351 } 352 }
352 } 353 }
353 354
354 } // namespace metrics 355 } // namespace metrics
OLDNEW
« no previous file with comments | « components/infobars/core/infobar_manager.cc ('k') | components/metrics/metrics_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698