Skip to content

Commit 7a0adb4

Browse files
dreamsxinnikic
authored andcommitted
Add #ifndef restrict
1 parent 714d825 commit 7a0adb4

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

Zend/zend_portability.h

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -239,11 +239,13 @@ char *alloca();
239239
# define ZEND_FASTCALL
240240
#endif
241241

242-
#if defined(__GNUC__) && ZEND_GCC_VERSION >= 3004
243-
#else
244-
# define __restrict__
242+
#ifndef restrict
243+
# if defined(__GNUC__) && ZEND_GCC_VERSION >= 3004
244+
# else
245+
# define __restrict__
246+
# endif
247+
# define restrict __restrict__
245248
#endif
246-
#define restrict __restrict__
247249

248250
#if (defined(__GNUC__) && __GNUC__ >= 3 && !defined(__INTEL_COMPILER) && !defined(DARWIN) && !defined(__hpux) && !defined(_AIX) && !defined(__osf__)) || __has_attribute(noreturn)
249251
# define HAVE_NORETURN

0 commit comments

Comments
 (0)