diff --git a/mozilla/xpcom/string/public/nsAString.h b/mozilla/xpcom/string/public/nsAString.h index fc761fe84f1..6fcc0a0eb20 100644 --- a/mozilla/xpcom/string/public/nsAString.h +++ b/mozilla/xpcom/string/public/nsAString.h @@ -53,9 +53,11 @@ // If some platform(s) can't handle our template that matches literal strings, // then we'll disable it on those platforms. -#if !defined(NS_DISABLE_LITERAL_TEMPLATE) && (defined(_MSC_VER) && _MSC_VER < 1310) -#define NS_DISABLE_LITERAL_TEMPLATE -#endif +#ifndef NS_DISABLE_LITERAL_TEMPLATE +# if (defined(_MSC_VER) && (_MSC_VER < 1310)) || (defined(__SUNPRO_CC) & (__SUNPRO_CC < 0x560)) +# define NS_DISABLE_LITERAL_TEMPLATE +# endif +#endif /* !NS_DISABLE_LITERAL_TEMPLATE */ #include diff --git a/mozilla/xpcom/string/public/nsSubstring.h b/mozilla/xpcom/string/public/nsSubstring.h index 937d0cac02e..f0842cf571d 100644 --- a/mozilla/xpcom/string/public/nsSubstring.h +++ b/mozilla/xpcom/string/public/nsSubstring.h @@ -47,9 +47,11 @@ // If some platform(s) can't handle our template that matches literal strings, // then we'll disable it on those platforms. -#if !defined(NS_DISABLE_LITERAL_TEMPLATE) && (defined(_MSC_VER) && _MSC_VER < 1310) -#define NS_DISABLE_LITERAL_TEMPLATE -#endif +#ifndef NS_DISABLE_LITERAL_TEMPLATE +# if (defined(_MSC_VER) && (_MSC_VER < 1310)) || (defined(__SUNPRO_CC) & (__SUNPRO_CC < 0x560)) +# define NS_DISABLE_LITERAL_TEMPLATE +# endif +#endif /* !NS_DISABLE_LITERAL_TEMPLATE */ #include