diff options
author | Evan Miller <emmiller@gmail.com> | 2023-07-14 14:55:56 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-14 21:55:56 +0300 |
commit | e8035f141e1f71d739fa5cfc9c01531cdee6fc16 (patch) | |
tree | 91c4a0527fb4fb5ad7f03457675c1b2e5c59af73 /k_quants.h | |
parent | 7513b7b0a1c11faa00ad5a34d22681e5f07d32e4 (diff) |
ggml : fix static_assert with older compilers #2024 (#2218)
Diffstat (limited to 'k_quants.h')
-rw-r--r-- | k_quants.h | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -15,6 +15,14 @@ #define K_SCALE_SIZE 12 #endif +#ifndef static_assert +#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 201100L) +#define static_assert(cond, msg) _Static_assert(cond, msg) +#else +#define static_assert(cond, msg) struct global_scope_noop_trick +#endif +#endif + // // Super-block quantization structures // |