diff src/evalfunc.c @ 17916:2e53305f2239 v8.1.1954

patch 8.1.1954: more functions can be used as a method Commit: https://github.com/vim/vim/commit/02b31110d31e995326080807716e79e38fe501df Author: Bram Moolenaar <Bram@vim.org> Date: Sat Aug 31 22:16:38 2019 +0200 patch 8.1.1954: more functions can be used as a method Problem: More functions can be used as a method. Solution: Allow more functions to be used as a method.
author Bram Moolenaar <Bram@vim.org>
date Sat, 31 Aug 2019 22:30:03 +0200
parents af3d441845cd
children 34639bba19b0
line wrap: on
line diff
--- a/src/evalfunc.c
+++ b/src/evalfunc.c
@@ -635,29 +635,29 @@ static funcentry_T global_functions[] =
     {"job_stop",	1, 2, FEARG_1,	  f_job_stop},
 #endif
     {"join",		1, 2, FEARG_1,	  f_join},
-    {"js_decode",	1, 1, 0,	  f_js_decode},
-    {"js_encode",	1, 1, 0,	  f_js_encode},
-    {"json_decode",	1, 1, 0,	  f_json_decode},
-    {"json_encode",	1, 1, 0,	  f_json_encode},
+    {"js_decode",	1, 1, FEARG_1,	  f_js_decode},
+    {"js_encode",	1, 1, FEARG_1,	  f_js_encode},
+    {"json_decode",	1, 1, FEARG_1,	  f_json_decode},
+    {"json_encode",	1, 1, FEARG_1,	  f_json_encode},
     {"keys",		1, 1, FEARG_1,	  f_keys},
     {"last_buffer_nr",	0, 0, 0,	  f_last_buffer_nr}, // obsolete
     {"len",		1, 1, FEARG_1,	  f_len},
-    {"libcall",		3, 3, 0,	  f_libcall},
-    {"libcallnr",	3, 3, 0,	  f_libcallnr},
-    {"line",		1, 1, 0,	  f_line},
-    {"line2byte",	1, 1, 0,	  f_line2byte},
-    {"lispindent",	1, 1, 0,	  f_lispindent},
-    {"list2str",	1, 2, 0,	  f_list2str},
-    {"listener_add",	1, 2, 0,	  f_listener_add},
-    {"listener_flush",	0, 1, 0,	  f_listener_flush},
-    {"listener_remove",	1, 1, 0,	  f_listener_remove},
+    {"libcall",		3, 3, FEARG_3,	  f_libcall},
+    {"libcallnr",	3, 3, FEARG_3,	  f_libcallnr},
+    {"line",		1, 1, FEARG_1,	  f_line},
+    {"line2byte",	1, 1, FEARG_1,	  f_line2byte},
+    {"lispindent",	1, 1, FEARG_1,	  f_lispindent},
+    {"list2str",	1, 2, FEARG_1,	  f_list2str},
+    {"listener_add",	1, 2, FEARG_2,	  f_listener_add},
+    {"listener_flush",	0, 1, FEARG_1,	  f_listener_flush},
+    {"listener_remove",	1, 1, FEARG_1,	  f_listener_remove},
     {"localtime",	0, 0, 0,	  f_localtime},
 #ifdef FEAT_FLOAT
     {"log",		1, 1, FEARG_1,	  f_log},
     {"log10",		1, 1, FEARG_1,	  f_log10},
 #endif
 #ifdef FEAT_LUA
-    {"luaeval",		1, 2, 0,	  f_luaeval},
+    {"luaeval",		1, 2, FEARG_1,	  f_luaeval},
 #endif
     {"map",		2, 2, FEARG_1,	  f_map},
     {"maparg",		1, 4, 0,	  f_maparg},