[Win] Warning fix.
authorpeavo@outlook.com <peavo@outlook.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 3 May 2016 17:58:23 +0000 (17:58 +0000)
committerpeavo@outlook.com <peavo@outlook.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 3 May 2016 17:58:23 +0000 (17:58 +0000)
https://bugs.webkit.org/show_bug.cgi?id=157309

Reviewed by Darin Adler.

MSVC gives a warning when converting from signed to unsigned.

* wtf/SmallPtrSet.h:
(WTF::SmallPtrSet::begin):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200380 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WTF/ChangeLog
Source/WTF/wtf/SmallPtrSet.h

index 0d26c5c..7b6b92c 100644 (file)
@@ -1,3 +1,15 @@
+2016-05-03  Per Arne Vollan  <peavo@outlook.com>
+
+        [Win] Warning fix.
+        https://bugs.webkit.org/show_bug.cgi?id=157309
+
+        Reviewed by Darin Adler.
+
+        MSVC gives a warning when converting from signed to unsigned.
+
+        * wtf/SmallPtrSet.h:
+        (WTF::SmallPtrSet::begin):
+
 2016-05-02  Brady Eidson  <beidson@apple.com>
 
         Add the ability to accumulate logs for specific logging channels to help diagnose test timeouts.
index 9c70bd8..7a5efc4 100644 (file)
@@ -147,7 +147,7 @@ public:
     iterator begin() const
     {
         iterator it;
-        it.m_index = -1;
+        it.m_index = std::numeric_limits<unsigned>::max();
         it.m_capacity = m_capacity;
         if (isSmall())
             it.m_buffer = const_cast<void**>(m_smallStorage);