Title: [150419] trunk/Source/WTF
Revision
150419
Author
[email protected]
Date
2013-05-20 23:11:34 -0700 (Mon, 20 May 2013)

Log Message

Use '__typeof__' keyword to avoid problems when compiling in C++11 standard compliance
https://bugs.webkit.org/show_bug.cgi?id=116447

Reviewed by Darin Adler.

The 'typeof' keyword is a GNU C extension which becomes unavailable when compiling in ANSI or specific standard mode
(such as -std=c++11). The '__typeof__' keyword should be used instead as it's available in all modes both under GCC and Clang.

* wtf/FastMalloc.cpp:
(WTF): Replace the 'typeof' keyword with '__typeof__'.

Modified Paths

Diff

Modified: trunk/Source/WTF/ChangeLog (150418 => 150419)


--- trunk/Source/WTF/ChangeLog	2013-05-21 06:08:18 UTC (rev 150418)
+++ trunk/Source/WTF/ChangeLog	2013-05-21 06:11:34 UTC (rev 150419)
@@ -1,3 +1,16 @@
+2013-05-20  Zan Dobersek  <[email protected]>
+
+        Use '__typeof__' keyword to avoid problems when compiling in C++11 standard compliance
+        https://bugs.webkit.org/show_bug.cgi?id=116447
+
+        Reviewed by Darin Adler.
+
+        The 'typeof' keyword is a GNU C extension which becomes unavailable when compiling in ANSI or specific standard mode
+        (such as -std=c++11). The '__typeof__' keyword should be used instead as it's available in all modes both under GCC and Clang.
+
+        * wtf/FastMalloc.cpp:
+        (WTF): Replace the 'typeof' keyword with '__typeof__'.
+
 2013-05-19  Anders Carlsson  <[email protected]>
 
         Remove link prerendering code

Modified: trunk/Source/WTF/wtf/FastMalloc.cpp (150418 => 150419)


--- trunk/Source/WTF/wtf/FastMalloc.cpp	2013-05-21 06:08:18 UTC (rev 150418)
+++ trunk/Source/WTF/wtf/FastMalloc.cpp	2013-05-21 06:11:34 UTC (rev 150419)
@@ -555,7 +555,7 @@
 
 #define HARDENING_ENTROPY internalEntropyValue()
 #define ROTATE_VALUE(value, amount) (((value) >> (amount)) | ((value) << (sizeof(value) * 8 - (amount))))
-#define XOR_MASK_PTR_WITH_KEY(ptr, key, entropy) (reinterpret_cast<typeof(ptr)>(reinterpret_cast<uintptr_t>(ptr)^(ROTATE_VALUE(reinterpret_cast<uintptr_t>(key), MaskKeyShift)^entropy)))
+#define XOR_MASK_PTR_WITH_KEY(ptr, key, entropy) (reinterpret_cast<__typeof__(ptr)>(reinterpret_cast<uintptr_t>(ptr)^(ROTATE_VALUE(reinterpret_cast<uintptr_t>(key), MaskKeyShift)^entropy)))
 
 
 static ALWAYS_INLINE uint32_t freedObjectStartPoison()
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to