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

Unified Diff: mojo/edk/util/mutex.h

Issue 1426343002: EDK: Move mutex.*, cond_var.*, and thread_annotations.h to //mojo/edk/util. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: oops Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « mojo/edk/util/logging_internal.cc ('k') | mojo/edk/util/mutex.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/util/mutex.h
diff --git a/mojo/edk/system/mutex.h b/mojo/edk/util/mutex.h
similarity index 90%
rename from mojo/edk/system/mutex.h
rename to mojo/edk/util/mutex.h
index 0ce1ed396c6a237075cb2db7d76cecdcc807ef58..381ce7adc72b92c3506d009d3787e0ec7ca8271a 100644
--- a/mojo/edk/system/mutex.h
+++ b/mojo/edk/util/mutex.h
@@ -6,22 +6,21 @@
//
// TODO(vtl): Add support for non-exclusive (reader) locks.
-#ifndef MOJO_EDK_SYSTEM_MUTEX_H_
-#define MOJO_EDK_SYSTEM_MUTEX_H_
+#ifndef MOJO_EDK_UTIL_MUTEX_H_
+#define MOJO_EDK_UTIL_MUTEX_H_
#include <pthread.h>
-#include "mojo/edk/system/thread_annotations.h"
+#include "mojo/edk/util/thread_annotations.h"
#include "mojo/public/cpp/system/macros.h"
namespace mojo {
-namespace system {
-
-// So |Mutex| can friend it.
-class CondVar;
+namespace util {
// Mutex -----------------------------------------------------------------------
+class CondVar;
+
class MOJO_LOCKABLE Mutex {
public:
#if defined(NDEBUG) && !defined(DCHECK_ALWAYS_ON)
@@ -78,7 +77,7 @@ class MOJO_SCOPED_LOCKABLE MutexLocker {
MOJO_DISALLOW_COPY_AND_ASSIGN(MutexLocker);
};
-} // namespace system
+} // namespace util
} // namespace mojo
-#endif // MOJO_EDK_SYSTEM_MUTEX_H_
+#endif // MOJO_EDK_UTIL_MUTEX_H_
« no previous file with comments | « mojo/edk/util/logging_internal.cc ('k') | mojo/edk/util/mutex.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698