Skip to content

Commit

Permalink
lib/gmath: suppress -Wstrict-prototypes for BLAS/LAPACK wrapper header
Browse files Browse the repository at this point in the history
  • Loading branch information
nilason committed Aug 18, 2024
1 parent 6099746 commit dfd2910
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion include/grass/la.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ typedef long int __g77_longint;
typedef unsigned long int __g77_ulongint;

#include <g2c.h>
#else /* for gcc4+ */
#else /* for gcc4+ */
typedef int integer;
typedef unsigned int uinteger;
typedef char *address;
Expand All @@ -67,6 +67,14 @@ typedef unsigned long ulongint;
/* IO stuff */
typedef int ftnlen;

#if defined(__clang__)
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wstrict-prototypes"
#elif defined(__GNUC__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstrict-prototypes"
#endif

/* procedure parameter types for -A */
typedef int (*U_fp)();
typedef shortint (*J_fp)();
Expand All @@ -80,6 +88,12 @@ typedef shortlogical (*K_fp)();
typedef void (*H_fp)();
typedef int (*S_fp)();

#if defined(__clang__)
#pragma clang diagnostic pop
#elif defined(__GNUC__)
#pragma GCC diagnostic pop
#endif

/* E_fp is for real functions when -R is not specified */
typedef void C_f; /* complex function */
typedef void H_f; /* character function */
Expand Down

0 comments on commit dfd2910

Please sign in to comment.