]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
llama.h : add missing struct keyword for C compat in callback type (#2847)
authorigarnier <redacted>
Mon, 28 Aug 2023 08:19:59 +0000 (10:19 +0200)
committerGitHub <redacted>
Mon, 28 Aug 2023 08:19:59 +0000 (11:19 +0300)
llama.h

diff --git a/llama.h b/llama.h
index b084fe23c8fcc84a60bd8e0de87720fc362b59ac..7bb681d612cc5a3bf641a45012828feee3f0d3da 100644 (file)
--- a/llama.h
+++ b/llama.h
@@ -496,7 +496,7 @@ extern "C" {
     // Type of pointer to the beam_search_callback function.
     // void* callback_data is any custom data passed to llama_beam_search, that is subsequently
     // passed back to beam_search_callback. This avoids having to use global variables in the callback.
-    typedef void (*llama_beam_search_callback_fn_t)(void * callback_data, llama_beams_state);
+    typedef void (*llama_beam_search_callback_fn_t)(void * callback_data, struct llama_beams_state);
 
     /// @details Deterministically returns entire sentence constructed by a beam search.
     /// @param ctx Pointer to the llama_context.