From c598c3ac770b4ae1bdcda06224fa18300eac1455 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Tue, 7 Nov 2017 00:51:03 +0100 Subject: doc: deprecate 'highlight'; remove howto.txt (#7497) --- src/nvim/syntax.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/nvim/syntax.c') diff --git a/src/nvim/syntax.c b/src/nvim/syntax.c index 70bda42d83..913fd05482 100644 --- a/src/nvim/syntax.c +++ b/src/nvim/syntax.c @@ -79,7 +79,7 @@ struct hl_group { #define SG_LINK 8 // link has been set /// @} -// highlight groups for 'highlight' option +// builtin |highlight-groups| static garray_T highlight_ga = GA_EMPTY_INIT_VALUE; static inline struct hl_group * HL_TABLE(void) -- cgit From 0407ddb36464c46086b608baebf7eed8a9ab60d5 Mon Sep 17 00:00:00 2001 From: James McCoy Date: Sat, 11 Nov 2017 10:48:04 -0500 Subject: Use PRId64 to format Integer when calling api_set_error Integer is a 64-bit type so using %d can produce incorrect results. test/functional/api/highlight_spec.lua @ 35: highlight api nvim_get_hl_by_id ...W7Xi/neovim-0.2.1/test/functional/api/highlight_spec.lua:46: Expected objects to be the same. Passed in: (string) 'Invalid highlight id: 7671724' Expected: (string) 'Invalid highlight id: 30000' --- src/nvim/syntax.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/nvim/syntax.c') diff --git a/src/nvim/syntax.c b/src/nvim/syntax.c index 913fd05482..65490768c4 100644 --- a/src/nvim/syntax.c +++ b/src/nvim/syntax.c @@ -8256,7 +8256,7 @@ Dictionary hl_get_attr_by_id(Integer attr_id, Boolean rgb, Error *err) attrentry_T *aep = syn_cterm_attr2entry((int)attr_id); if (!aep) { api_set_error(err, kErrorTypeException, - "Invalid attribute id: %d", attr_id); + "Invalid attribute id: %" PRId64, attr_id); return dic; } -- cgit