forked from extern/whisper.cpp
ggml : make more compatible with c99 (#262)
This commit is contained in:
parent
5a5c5ddcca
commit
0f11759406
5
ggml.c
5
ggml.c
@ -14,9 +14,10 @@
|
|||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
// if C99 - static_assert is nop
|
// if C99 - static_assert is noop
|
||||||
|
// ref: https://stackoverflow.com/a/53923785/4039976
|
||||||
#ifndef static_assert
|
#ifndef static_assert
|
||||||
#define static_assert(cond, msg)
|
#define static_assert(cond, msg) struct global_scope_noop_trick
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined _MSC_VER || defined(__MINGW32__)
|
#if defined _MSC_VER || defined(__MINGW32__)
|
||||||
|
2
ggml.h
2
ggml.h
@ -681,7 +681,6 @@ struct ggml_opt_params {
|
|||||||
bool print_forward_graph;
|
bool print_forward_graph;
|
||||||
bool print_backward_graph;
|
bool print_backward_graph;
|
||||||
|
|
||||||
union {
|
|
||||||
// ADAM parameters
|
// ADAM parameters
|
||||||
struct {
|
struct {
|
||||||
int n_iter;
|
int n_iter;
|
||||||
@ -708,7 +707,6 @@ struct ggml_opt_params {
|
|||||||
|
|
||||||
enum ggml_linesearch linesearch;
|
enum ggml_linesearch linesearch;
|
||||||
} lbfgs;
|
} lbfgs;
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct ggml_opt_params ggml_opt_default_params(enum ggml_opt_type type);
|
struct ggml_opt_params ggml_opt_default_params(enum ggml_opt_type type);
|
||||||
|
Loading…
Reference in New Issue
Block a user