Bug 1079319 - Fix some more bad implicit constructors in intl; r=smontagu
authorEhsan Akhgari <ehsan@mozilla.com>
Wed, 24 Sep 2014 09:16:53 -0400
changeset 209342 1b195cb0d08d40117862c78776b757e93017e439
parent 209341 681c4450639e2d9c7ccca1e48514ed4a35bf6552
child 209343 8c00d59b1c0091495e1e5471693156adaccc39eb
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
reviewerssmontagu
bugs1079319
milestone35.0a1
Bug 1079319 - Fix some more bad implicit constructors in intl; r=smontagu
intl/locale/nsUConvPropertySearch.cpp
intl/unicharutil/nsUnicodeNormalizer.cpp
--- a/intl/locale/nsUConvPropertySearch.cpp
+++ b/intl/locale/nsUConvPropertySearch.cpp
@@ -7,17 +7,17 @@
 #include "nsString.h"
 #include "mozilla/BinarySearch.h"
 
 namespace {
 
 struct PropertyComparator
 {
   const nsCString& mKey;
-  PropertyComparator(const nsCString& aKey) : mKey(aKey) {}
+  explicit PropertyComparator(const nsCString& aKey) : mKey(aKey) {}
   int operator()(const char* (&aProperty)[3]) const {
     return mKey.Compare(aProperty[0]);
   }
 };
 
 }
 
 // static
--- a/intl/unicharutil/nsUnicodeNormalizer.cpp
+++ b/intl/unicharutil/nsUnicodeNormalizer.cpp
@@ -237,17 +237,17 @@ mdn__unicode_iscompositecandidate(uint32
 		return (1);
 }
 
 namespace {
 
 struct SequenceAdaptor
 {
 	const composition* const mSequence;
-	SequenceAdaptor(const composition* aSequence) : mSequence(aSequence) {}
+	explicit SequenceAdaptor(const composition* aSequence) : mSequence(aSequence) {}
 	uint32_t operator[](size_t aIdx) const {
 		return mSequence[aIdx].c2;
 	}
 };
 
 } // namespace
 
 static nsresult