summaryrefslogtreecommitdiff
path: root/www/firefox/patches/patch-mfbt_Attributes.h
blob: fa549e6b96004046ff48b7fa2c427dbc8678d0f3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
$NetBSD: patch-mfbt_Attributes.h,v 1.1 2014/07/24 14:57:12 ryoon Exp $

--- mfbt/Attributes.h.orig	2014-07-17 01:45:32.000000000 +0000
+++ mfbt/Attributes.h
@@ -54,6 +54,9 @@
 #  ifndef __has_extension
 #    define __has_extension __has_feature /* compatibility, for older versions of clang */
 #  endif
+#  if __has_extension(cxx_alignas)
+#    define MOZ_HAVE_CXX11_ALIGNAS
+#  endif
 #  if __has_extension(cxx_constexpr)
 #    define MOZ_HAVE_CXX11_CONSTEXPR
 #  endif
@@ -75,6 +78,9 @@
 #  endif
 #elif defined(__GNUC__)
 #  if defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L
+#    if MOZ_GCC_VERSION_AT_LEAST(4, 8, 0)
+#      define MOZ_HAVE_CXX11_ALIGNAS
+#    endif
 #    if MOZ_GCC_VERSION_AT_LEAST(4, 7, 0)
 #      define MOZ_HAVE_CXX11_OVERRIDE
 #      define MOZ_HAVE_CXX11_FINAL       final
@@ -96,6 +102,7 @@
 #  define MOZ_HAVE_NORETURN              __attribute__((noreturn))
 #elif defined(_MSC_VER)
 #  if _MSC_VER >= 1800
+#    define MOZ_HAVE_CXX11_ALIGNAS
 #    define MOZ_HAVE_CXX11_DELETE
 #  endif
 #  if _MSC_VER >= 1700