diff options
author | ZyX <kp-pav@yandex.ru> | 2016-09-04 18:40:19 +0300 |
---|---|---|
committer | ZyX <kp-pav@yandex.ru> | 2017-03-29 10:08:06 +0300 |
commit | 86fc4580b83f20211d7f85566e84a0e1dad0a136 (patch) | |
tree | 2750d26254c86f2144a65f18f00a8848d8b8f7f3 /src/nvim/eval/typval.h | |
parent | c4fe656fef5ade20da4861a2f1e5d0f776b0df8f (diff) | |
download | rneovim-86fc4580b83f20211d7f85566e84a0e1dad0a136.tar.gz rneovim-86fc4580b83f20211d7f85566e84a0e1dad0a136.tar.bz2 rneovim-86fc4580b83f20211d7f85566e84a0e1dad0a136.zip |
eval: Fix max_min functions
Found two bugs:
1. Multiple unneeded error messages, vim/vim#1039.
2. Unformatted error string, vim/vim#1040.
Diffstat (limited to 'src/nvim/eval/typval.h')
-rw-r--r-- | src/nvim/eval/typval.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/eval/typval.h b/src/nvim/eval/typval.h index 42581939e3..3b41314b46 100644 --- a/src/nvim/eval/typval.h +++ b/src/nvim/eval/typval.h @@ -279,13 +279,13 @@ typedef struct list_stack_S { #define TV_DICT_HI2DI(hi) \ ((dictitem_T *)((hi)->hi_key - offsetof(dictitem_T, di_key))) -static inline long tv_list_len(list_T *const l) +static inline long tv_list_len(const list_T *const l) REAL_FATTR_PURE REAL_FATTR_WARN_UNUSED_RESULT; /// Get the number of items in a list /// /// @param[in] l List to check. -static inline long tv_list_len(list_T *const l) +static inline long tv_list_len(const list_T *const l) { if (l == NULL) { return 0; |