|
37 | 37 | #elif defined __clang__
|
38 | 38 | // -Wconstant-logical-operand - warning: use of logical && with constant operand; switch to bitwise & or remove constant
|
39 | 39 | // this is really a stupid warning as it warns on compile-time expressions involving enums
|
40 |
| - #ifndef EIGEN_PERMANENTLY_DISABLE_STUPID_WARNINGS |
41 |
| - #pragma clang diagnostic push |
42 |
| - #endif |
43 |
| - #pragma clang diagnostic ignored "-Wconstant-logical-operand" |
44 |
| - #if __clang_major__ >= 3 && __clang_minor__ >= 5 |
45 |
| - #pragma clang diagnostic ignored "-Wabsolute-value" |
46 |
| - #endif |
47 |
| - #if __clang_major__ >= 10 |
48 |
| - #pragma clang diagnostic ignored "-Wimplicit-int-float-conversion" |
49 |
| - #endif |
50 |
| - #if ( defined(__ALTIVEC__) || defined(__VSX__) ) && __cplusplus < 201103L |
51 |
| - // warning: generic selections are a C11-specific feature |
52 |
| - // ignoring warnings thrown at vec_ctf in Altivec/PacketMath.h |
53 |
| - #pragma clang diagnostic ignored "-Wc11-extensions" |
54 |
| - #endif |
| 40 | + // #ifndef EIGEN_PERMANENTLY_DISABLE_STUPID_WARNINGS |
| 41 | + // #pragma clang diagnostic push |
| 42 | + // #endif |
| 43 | + // #pragma clang diagnostic ignored "-Wconstant-logical-operand" |
| 44 | + // #if __clang_major__ >= 3 && __clang_minor__ >= 5 |
| 45 | + // #pragma clang diagnostic ignored "-Wabsolute-value" |
| 46 | + // #endif |
| 47 | + // #if __clang_major__ >= 10 |
| 48 | + // #pragma clang diagnostic ignored "-Wimplicit-int-float-conversion" |
| 49 | + // #endif |
| 50 | + // #if ( defined(__ALTIVEC__) || defined(__VSX__) ) && __cplusplus < 201103L |
| 51 | + // // warning: generic selections are a C11-specific feature |
| 52 | + // // ignoring warnings thrown at vec_ctf in Altivec/PacketMath.h |
| 53 | + // #pragma clang diagnostic ignored "-Wc11-extensions" |
| 54 | + // #endif |
55 | 55 |
|
56 | 56 | #elif defined __GNUC__
|
57 | 57 |
|
58 |
| - #if (!defined(EIGEN_PERMANENTLY_DISABLE_STUPID_WARNINGS)) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)) |
59 |
| - #pragma GCC diagnostic push |
60 |
| - #endif |
61 |
| - // g++ warns about local variables shadowing member functions, which is too strict |
62 |
| - #pragma GCC diagnostic ignored "-Wshadow" |
63 |
| - #if __GNUC__ == 4 && __GNUC_MINOR__ < 8 |
64 |
| - // Until g++-4.7 there are warnings when comparing unsigned int vs 0, even in templated functions: |
65 |
| - #pragma GCC diagnostic ignored "-Wtype-limits" |
66 |
| - #endif |
67 |
| - #if __GNUC__>=6 |
68 |
| - #pragma GCC diagnostic ignored "-Wignored-attributes" |
69 |
| - #endif |
70 |
| - #if __GNUC__==7 |
71 |
| - // See: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89325 |
72 |
| - #pragma GCC diagnostic ignored "-Wattributes" |
73 |
| - #endif |
| 58 | + // #if (!defined(EIGEN_PERMANENTLY_DISABLE_STUPID_WARNINGS)) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)) |
| 59 | + // #pragma GCC diagnostic push |
| 60 | + // #endif |
| 61 | + // // g++ warns about local variables shadowing member functions, which is too strict |
| 62 | + // #pragma GCC diagnostic ignored "-Wshadow" |
| 63 | + // #if __GNUC__ == 4 && __GNUC_MINOR__ < 8 |
| 64 | + // // Until g++-4.7 there are warnings when comparing unsigned int vs 0, even in templated functions: |
| 65 | + // #pragma GCC diagnostic ignored "-Wtype-limits" |
| 66 | + // #endif |
| 67 | + // #if __GNUC__>=6 |
| 68 | + // #pragma GCC diagnostic ignored "-Wignored-attributes" |
| 69 | + // #endif |
| 70 | + // #if __GNUC__==7 |
| 71 | + // // See: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89325 |
| 72 | + // #pragma GCC diagnostic ignored "-Wattributes" |
| 73 | + // #endif |
74 | 74 | #endif
|
75 | 75 |
|
76 | 76 | #if defined __NVCC__
|
|
0 commit comments