Bug 1322465 part 9 - Use explicit/MOZ_IMPLICIT for the unary constructors in mozglue/. r=Ehsan
authorTing-Yu Chou <janus926@gmail.com>
Fri, 16 Dec 2016 15:57:53 +0800
changeset 326875 da42a29cc2e256a9c27ed3e329aa128ef13a5159
parent 326874 1090a9912c2643aded14a7cc7ffa0e23203d3914
child 326876 5e5f1ae09fb03a98d0bb54cf944656068b977f5f
push id31114
push usercbook@mozilla.com
push dateThu, 22 Dec 2016 15:19:05 +0000
treeherdermozilla-central@8460203bc93b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersEhsan
bugs1322465
milestone53.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1322465 part 9 - Use explicit/MOZ_IMPLICIT for the unary constructors in mozglue/. r=Ehsan MozReview-Commit-ID: MHgGyQGRdM
mozglue/misc/TimeStamp_windows.cpp
mozglue/misc/TimeStamp_windows.h
--- a/mozglue/misc/TimeStamp_windows.cpp
+++ b/mozglue/misc/TimeStamp_windows.cpp
@@ -15,17 +15,17 @@
 #include <windows.h>
 
 // To enable logging define to your favorite logging API
 #define LOG(x)
 
 class AutoCriticalSection
 {
 public:
-  AutoCriticalSection(LPCRITICAL_SECTION aSection)
+  explicit AutoCriticalSection(LPCRITICAL_SECTION aSection)
     : mSection(aSection)
   {
     ::EnterCriticalSection(mSection);
   }
   ~AutoCriticalSection()
   {
     ::LeaveCriticalSection(mSection);
   }
--- a/mozglue/misc/TimeStamp_windows.h
+++ b/mozglue/misc/TimeStamp_windows.h
@@ -25,17 +25,17 @@ class TimeStampValue
   bool mHasQPC;
   bool mIsNull;
 
   MFBT_API TimeStampValue(uint64_t aGTC, uint64_t aQPC, bool aHasQPC);
 
   MFBT_API uint64_t CheckQPC(const TimeStampValue& aOther) const;
 
   struct _SomethingVeryRandomHere;
-  constexpr TimeStampValue(_SomethingVeryRandomHere* aNullValue)
+  constexpr MOZ_IMPLICIT TimeStampValue(_SomethingVeryRandomHere* aNullValue)
     : mGTC(0)
     , mQPC(0)
     , mHasQPC(false)
     , mIsNull(true)
   {
   }
 
 public: