Skip to content

Commit 4d63f3f

Browse files
author
ripley
committed
gcc does not ignore # pragma clang as it should
git-svn-id: https://svn.r-project.org/R/trunk@87784 00db46b3-68df-0310-9c12-caf00c1e9a41
1 parent 4555d50 commit 4d63f3f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/main/memory.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2358,7 +2358,9 @@ long double *R_allocLD(size_t nelem)
23582358
#elif __GNUC__
23592359
// This is C99, but do not rely on it.
23602360
// Apple clang warns this is gnu extension.
2361+
#ifdef __clang__
23612362
# pragma clang diagnostic ignored "-Wgnu-offsetof-extensions"
2363+
#endif
23622364
size_t ld_align = offsetof(struct { char __a; long double __b; }, __b);
23632365
#else
23642366
size_t ld_align = 0x0F; // value of x86_64, known others are 4 or 8

0 commit comments

Comments
 (0)