Skip to content

Commit

Permalink
Try pragma ignore
Browse files Browse the repository at this point in the history
  • Loading branch information
lysnikolaou committed Jul 5, 2023
1 parent ad60798 commit 30b3af7
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions numpy/core/include/numpy/npy_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -419,6 +419,10 @@ typedef union {
} _npy_clongdouble_to_arr;
#endif

#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif
static inline double NPY_CDOUBLE_GET_REAL(const npy_cdouble *c) {
#ifdef __cplusplus
return reinterpret_cast<const double *>(c)[0];
Expand Down Expand Up @@ -551,6 +555,10 @@ static inline void NPY_CLONGDOUBLE_SET_IMAG(npy_clongdouble *c, longdouble_t ima
#endif
}

#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif

/*
* numarray-style bit-width typedefs
*/
Expand Down

0 comments on commit 30b3af7

Please sign in to comment.