Skip to content

Commit 2ddc12f

Browse files
Use Intel specific pragma to disable unknown attribute warning (#278)
* Use Intel specific pragma to disable unknown attribute warning * NEWS bullet * Update NEWS.md Co-authored-by: Romain François <[email protected]> * Wrap to 80 characters Co-authored-by: Romain François <[email protected]>
1 parent 2aba46e commit 2ddc12f

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

NEWS.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# cpp11 (development version)
22

3+
* Silenced an unknown attribute warning specific to the Intel compiler
4+
(r-lib/systemfonts#98).
5+
36
# cpp11 0.4.3
47

58
* Modernized the GitHub Actions workflows and updated some internal tests to

inst/include/cpp11/R.hpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,16 @@
1313
#include "Rinternals.h"
1414

1515
// clang-format off
16-
#ifdef __clang__
16+
#if defined(__INTEL_COMPILER)
17+
# pragma warning(disable : 3924)
18+
#endif
19+
20+
#if defined(__clang__)
1721
# pragma clang diagnostic push
1822
# pragma clang diagnostic ignored "-Wattributes"
1923
#endif
2024

21-
#ifdef __GNUC__
25+
#if defined(__GNUC__) && !defined(__clang__) && !defined(__INTEL_COMPILER)
2226
# pragma GCC diagnostic push
2327
# pragma GCC diagnostic ignored "-Wattributes"
2428
#endif

0 commit comments

Comments
 (0)