diff options
| author | ame <[email protected]> | 2023-12-18 13:55:13 -0600 |
|---|---|---|
| committer | ame <[email protected]> | 2023-12-18 13:55:13 -0600 |
| commit | 595fd25a80c569d104bc53cbfb9e46654134b4e1 (patch) | |
| tree | 17506097f415d4bddcdf3566d3ce0de08ab9a377 /src/config.h | |
| parent | c691cc98e31e52982a79ffc10b8e91e8c700592b (diff) | |
config and io functions
Diffstat (limited to 'src/config.h')
| -rw-r--r-- | src/config.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/config.h b/src/config.h new file mode 100644 index 0000000..1d45cad --- /dev/null +++ b/src/config.h @@ -0,0 +1,25 @@ +#include "lua.h" + + +extern int _print_type; +extern int _max_depth; +extern int _start_nl_at; + +struct str_to_int { + const char* key; + int* value; +}; + +static struct str_to_int config_map[] = { + {"print_type", &_print_type}, + {"max_depth", &_max_depth}, + {"start_nl_at", &_start_nl_at}, + {NULL,NULL} +}; + +int l_set(lua_State*); + +static const luaL_Reg config_function_list [] = { + {"set",l_set}, + {NULL,NULL} +}; |
