Bug 673865 - WebGLContextGL.cpp failed to compile with Solaris Studio. r=bjacob.
authorGinn Chen <ginn.chen@oracle.com>
Thu, 28 Jul 2011 11:42:22 +0800
changeset 73459 6e4459932781a74adc5a6bb7c11bc4c0fee3e64b
parent 73458 f28edbb721b8fe7ca252b8c218836290b4a0ae43
child 73460 6298f984ef2cda23f3baa896c2e3e998a7a69abf
push id20871
push usereakhgari@mozilla.com
push dateThu, 28 Jul 2011 14:37:48 +0000
treeherdermozilla-central@fe48bbfeff94 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbjacob
bugs673865
milestone8.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 673865 - WebGLContextGL.cpp failed to compile with Solaris Studio. r=bjacob.
content/canvas/src/WebGLTexelConversions.h
--- a/content/canvas/src/WebGLTexelConversions.h
+++ b/content/canvas/src/WebGLTexelConversions.h
@@ -28,22 +28,26 @@
 // the pixel conversions code here is originally from this file:
 //   http://trac.webkit.org/browser/trunk/WebCore/platform/graphics/GraphicsContext3D.cpp
 
 // Keep as much as possible unchanged to ease sharing code with the WebKit guys.
 // Changes:
 //  * added BGR8 path, we need it in Mozilla to load textures from DOMElements
 //  * enclosing in a namespace WebGLTexelConversions to make it clear it is, in profilers and in symbol table dumps
 //  * added __restrict keywords. Although non-standard, this is very well supported across all compilers
-//    that I know of (GCC/LLVM/MSC/ICC/Sun/XLC...)
+//    that I know of (GCC/LLVM/MSC/ICC/XLC...)
 //  * optimized scaleFactor computation in Unmultiply functions (1 div instead of 2)
 
 #ifndef WEBGLTEXELCONVERSIONS_H_
 #define WEBGLTEXELCONVERSIONS_H_
 
+#ifdef __SUNPRO_CC
+#define __restrict
+#endif
+
 #include "WebGLContext.h"
 
 namespace mozilla {
 
 typedef PRUint8  uint8_t;
 typedef PRUint16 uint16_t;
 
 namespace { // this is only included by WebGLContextGL.cpp anyway