diff options
Diffstat (limited to 'src/nvim/types.h')
-rw-r--r-- | src/nvim/types.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/nvim/types.h b/src/nvim/types.h index 477102276c..d90c623955 100644 --- a/src/nvim/types.h +++ b/src/nvim/types.h @@ -22,7 +22,16 @@ typedef int handle_T; // absent callback etc. typedef int LuaRef; -typedef void (*FunPtr)(void); +/// Type used for VimL VAR_FLOAT values +typedef double float_T; + +typedef struct MsgpackRpcRequestHandler MsgpackRpcRequestHandler; + +typedef union { + float_T (*float_func)(float_T); + const MsgpackRpcRequestHandler *api_handler; + void *nullptr; +} EvalFuncData; typedef handle_T NS; @@ -36,6 +45,9 @@ typedef enum { kTrue = 1, } TriState; +#define TRISTATE_TO_BOOL(val, \ + default) ((val) == kTrue ? true : ((val) == kFalse ? false : (default))) + typedef struct Decoration Decoration; #endif // NVIM_TYPES_H |