cmdhist.h (1198B)
1 #pragma once 2 3 #include <stddef.h> // IWYU pragma: keep 4 5 #include "nvim/cmdexpand_defs.h" // IWYU pragma: keep 6 #include "nvim/eval/typval_defs.h" // IWYU pragma: keep 7 #include "nvim/ex_cmds_defs.h" // IWYU pragma: keep 8 #include "nvim/os/time_defs.h" 9 #include "nvim/types_defs.h" // IWYU pragma: keep 10 11 /// Present history tables 12 typedef enum { 13 HIST_DEFAULT = -2, ///< Default (current) history. 14 HIST_INVALID = -1, ///< Unknown history. 15 HIST_CMD = 0, ///< Colon commands. 16 HIST_SEARCH, ///< Search commands. 17 HIST_EXPR, ///< Expressions (e.g. from entering = register). 18 HIST_INPUT, ///< input() lines. 19 HIST_DEBUG, ///< Debug commands. 20 } HistoryType; 21 22 enum { HIST_COUNT = HIST_DEBUG + 1, }; ///< Number of history tables 23 24 /// History entry definition 25 typedef struct { 26 int hisnum; ///< Entry identifier number. 27 char *hisstr; ///< Actual entry, separator char after the NUL. 28 size_t hisstrlen; ///< Length of hisstr (excluding the NUL). 29 Timestamp timestamp; ///< Time when entry was added. 30 AdditionalData *additional_data; ///< Additional entries from ShaDa file. 31 } histentry_T; 32 33 #include "cmdhist.h.generated.h"