diff options
author | ZyX <kp-pav@yandex.ru> | 2016-06-26 17:56:25 +0300 |
---|---|---|
committer | ZyX <kp-pav@yandex.ru> | 2016-07-10 02:04:27 +0300 |
commit | 1a92585e320812ae113a4d4ec6769b1978bedfe3 (patch) | |
tree | 9d744c468ee49c712c11b6fc11b7111bc13a4007 | |
parent | c47624482c4ec23d055e30ecb3e24b04794f1235 (diff) | |
download | rneovim-1a92585e320812ae113a4d4ec6769b1978bedfe3.tar.gz rneovim-1a92585e320812ae113a4d4ec6769b1978bedfe3.tar.bz2 rneovim-1a92585e320812ae113a4d4ec6769b1978bedfe3.zip |
option.h: Turn OPT_* list into a enum
-rw-r--r-- | src/nvim/option.h | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/src/nvim/option.h b/src/nvim/option.h index 5c2b2662b5..3a43b859a8 100644 --- a/src/nvim/option.h +++ b/src/nvim/option.h @@ -6,17 +6,18 @@ #define BCO_ALWAYS 2 /* always copy the options */ #define BCO_NOHELP 4 /* don't touch the help related options */ -/* - * "flags" values for option-setting functions. - * When OPT_GLOBAL and OPT_LOCAL are both missing, set both local and global - * values, get local value. - */ -#define OPT_FREE 1 /* free old value if it was allocated */ -#define OPT_GLOBAL 2 /* use global value */ -#define OPT_LOCAL 4 /* use local value */ -#define OPT_MODELINE 8 /* option in modeline */ -#define OPT_WINONLY 16 /* only set window-local options */ -#define OPT_NOWIN 32 /* don't set window-local options */ +/// Flags for option-setting functions +/// +/// When OPT_GLOBAL and OPT_LOCAL are both missing, set both local and global +/// values, get local value. +typedef enum { + OPT_FREE = 1, ///< Free old value if it was allocated. + OPT_GLOBAL = 2, ///< Use global value. + OPT_LOCAL = 4, ///< Use local value. + OPT_MODELINE = 8, ///< Option in modeline. + OPT_WINONLY = 16, ///< Only set window-local options. + OPT_NOWIN = 32, ///< Don’t set window-local options. +} OptionFlags; #ifdef INCLUDE_GENERATED_DECLARATIONS # include "option.h.generated.h" |