From 30211fa4a3d65e7f26640d0c2caba3e5b48312b1 Mon Sep 17 00:00:00 2001 From: sanine-a Date: Sun, 23 May 2021 22:54:25 -0500 Subject: add all function definitions in honeysuckle.h --- src/honeysuckle.h | 20 +++++++++++++++++++- src/test.c | 3 ++- 2 files changed, 21 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/honeysuckle.h b/src/honeysuckle.h index 7538791..b996aed 100644 --- a/src/honeysuckle.h +++ b/src/honeysuckle.h @@ -5,7 +5,6 @@ #include #include - #define HS_END 0 /* type constants */ @@ -21,7 +20,26 @@ #define HS_NIL 10 #define HS_ANY 11 +const char* hs_type_to_string(int type); + +void hs_parse_args(lua_State *L, ...); +void hs_parse_args_fast(lua_State *L, ...); +int hs_parse_overloaded(lua_State *L, ...); + +int hs_create_table(lua_State *L, ...); +int hs_create_enum(lua_State *L, ...); + +void hs_process_table(lua_State *L, int table_index, void *data, ...); + +void hs_throw_error(lua_State *L, const char *format_string, ...); +int hs_traceback(lua_State *L); +int hs_call(lua_State *L); +int hs_call_args(lua_State *L, ...); void hs_pushstring(lua_State *L, const char *format_string, ...); +#define hs_rstore(L) luaL_ref(L, LUA_REGISTRYINDEX); +#define hs_rload(L, ref) lua_rawgeti(L, LUA_REGISTRYINDEX, ref) +#define hs_rdel(L, ref) luaL_unref(L, LUA_REGISTRYINDEX, ref) + #endif diff --git a/src/test.c b/src/test.c index 5275d4d..5a74414 100644 --- a/src/test.c +++ b/src/test.c @@ -7,7 +7,8 @@ #include "honeysuckle.h" -/* minunit testing macros modified from those at www.jera.com/techinfo/jtns/jtn002.html */ +/* minunit testing macros modified from those at + www.jera.com/techinfo/jtns/jtn002.html */ #define mu_assert(message, test) do { if (!(test)) return message; } while (0) #define mu_run_test(name, test) do { \ lua_State *L = luaL_newstate(); \ -- cgit v1.2.1