freebsd-ports/lang/v8-devel/files/patch-src-objects.h
Sunpoet Po-Chuan Hsieh 550e05b2ad - Fix warnings generated by recent snapshot of Clang 3.7.0, including:
- Printing non-void pointers with %p.
  - Left-shifting negative numbers.

PR:		202534
Submitted by:	dim
2015-09-20 20:18:02 +00:00

13 lines
586 B
C

--- src/objects.h.orig 2014-06-03 08:52:11 UTC
+++ src/objects.h
@@ -8824,8 +8824,8 @@ class Name: public HeapObject {
STATIC_ASSERT(IS_POWER_OF_TWO(kMaxCachedArrayIndexLength + 1));
static const unsigned int kContainsCachedArrayIndexMask =
- (~kMaxCachedArrayIndexLength << ArrayIndexLengthBits::kShift) |
- kIsNotArrayIndexMask;
+ (~static_cast<unsigned>(kMaxCachedArrayIndexLength)
+ << ArrayIndexLengthBits::kShift) | kIsNotArrayIndexMask;
// Value of empty hash field indicating that the hash is not computed.
static const int kEmptyHashField =