summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Minor <dminor@mozilla.com>2017-03-28 16:04:41 -0400
committerAndreas Schuh <andreas.schuh.84@gmail.com>2017-03-29 13:01:34 +0100
commit9314597d4b742ed6f95665241345e590a0f5759b (patch)
tree7e82667d870963bf7afd6108c154b3a75950bc64
parent30dbc81fb5ffdc98ea9b14b1918bfe4e8779b26e (diff)
downloadgflags-9314597d4b742ed6f95665241345e590a0f5759b.tar.gz
gflags-9314597d4b742ed6f95665241345e590a0f5759b.tar.bz2
gflags-9314597d4b742ed6f95665241345e590a0f5759b.zip
Mark single argument constructors in mutex.h as explicit.
-rw-r--r--src/mutex.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mutex.h b/src/mutex.h
index 1648c2f..7d7c364 100644
--- a/src/mutex.h
+++ b/src/mutex.h
@@ -166,7 +166,7 @@ class Mutex {
// It inhibits work being done by the destructor, which makes it
// safer for code that tries to acqiure this mutex in their global
// destructor.
- inline Mutex(LinkerInitialized);
+ explicit inline Mutex(LinkerInitialized);
// Destructor
inline ~Mutex();
@@ -197,7 +197,7 @@ class Mutex {
inline void SetIsSafe() { is_safe_ = true; }
// Catch the error of writing Mutex when intending MutexLock.
- Mutex(Mutex* /*ignored*/) {}
+ explicit Mutex(Mutex* /*ignored*/) {}
// Disallow "evil" constructors
Mutex(const Mutex&);
void operator=(const Mutex&);