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

Side by Side Diff: base/synchronization/cancellation_flag.h

Issue 1538743002: Switch to standard integer types in base/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: DEPS roll too Created 4 years, 12 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 unified diff | Download patch
« no previous file with comments | « base/sync_socket_win.cc ('k') | base/synchronization/condition_variable.h » ('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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef BASE_SYNCHRONIZATION_CANCELLATION_FLAG_H_ 5 #ifndef BASE_SYNCHRONIZATION_CANCELLATION_FLAG_H_
6 #define BASE_SYNCHRONIZATION_CANCELLATION_FLAG_H_ 6 #define BASE_SYNCHRONIZATION_CANCELLATION_FLAG_H_
7 7
8 #include "base/atomicops.h"
8 #include "base/base_export.h" 9 #include "base/base_export.h"
9 #include "base/atomicops.h" 10 #include "base/macros.h"
10 #include "base/threading/platform_thread.h" 11 #include "base/threading/platform_thread.h"
11 12
12 namespace base { 13 namespace base {
13 14
14 // CancellationFlag allows one thread to cancel jobs executed on some worker 15 // CancellationFlag allows one thread to cancel jobs executed on some worker
15 // thread. Calling Set() from one thread and IsSet() from a number of threads 16 // thread. Calling Set() from one thread and IsSet() from a number of threads
16 // is thread-safe. 17 // is thread-safe.
17 // 18 //
18 // This class IS NOT intended for synchronization between threads. 19 // This class IS NOT intended for synchronization between threads.
19 class BASE_EXPORT CancellationFlag { 20 class BASE_EXPORT CancellationFlag {
(...skipping 19 matching lines...) Expand all
39 #if !defined(NDEBUG) 40 #if !defined(NDEBUG)
40 PlatformThreadId set_on_; 41 PlatformThreadId set_on_;
41 #endif 42 #endif
42 43
43 DISALLOW_COPY_AND_ASSIGN(CancellationFlag); 44 DISALLOW_COPY_AND_ASSIGN(CancellationFlag);
44 }; 45 };
45 46
46 } // namespace base 47 } // namespace base
47 48
48 #endif // BASE_SYNCHRONIZATION_CANCELLATION_FLAG_H_ 49 #endif // BASE_SYNCHRONIZATION_CANCELLATION_FLAG_H_
OLDNEW
« no previous file with comments | « base/sync_socket_win.cc ('k') | base/synchronization/condition_variable.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698