diff src/evalfunc.c @ 18017:988e5a868b60 v8.1.2004

patch 8.1.2004: more functions can be used as methods Commit: https://github.com/vim/vim/commit/f6ed61e1489e40eada55a4f1782e1ed82bcad7d9 Author: Bram Moolenaar <Bram@vim.org> Date: Sat Sep 7 19:05:09 2019 +0200 patch 8.1.2004: more functions can be used as methods Problem: More functions can be used as methods. Solution: Make various functions usable as a method.
author Bram Moolenaar <Bram@vim.org>
date Sat, 07 Sep 2019 19:15:04 +0200
parents cf8e0c7e0cb9
children 8a2fb21c23c0
line wrap: on
line diff
--- a/src/evalfunc.c
+++ b/src/evalfunc.c
@@ -715,38 +715,38 @@ static funcentry_T global_functions[] =
     {"sort",		1, 3, FEARG_1,	  f_sort},
 #ifdef FEAT_SOUND
     {"sound_clear",	0, 0, 0,	  f_sound_clear},
-    {"sound_playevent",	1, 2, 0,	  f_sound_playevent},
-    {"sound_playfile",	1, 2, 0,	  f_sound_playfile},
-    {"sound_stop",	1, 1, 0,	  f_sound_stop},
-#endif
-    {"soundfold",	1, 1, 0,	  f_soundfold},
-    {"spellbadword",	0, 1, 0,	  f_spellbadword},
-    {"spellsuggest",	1, 3, 0,	  f_spellsuggest},
+    {"sound_playevent",	1, 2, FEARG_1,	  f_sound_playevent},
+    {"sound_playfile",	1, 2, FEARG_1,	  f_sound_playfile},
+    {"sound_stop",	1, 1, FEARG_1,	  f_sound_stop},
+#endif
+    {"soundfold",	1, 1, FEARG_1,	  f_soundfold},
+    {"spellbadword",	0, 1, FEARG_1,	  f_spellbadword},
+    {"spellsuggest",	1, 3, FEARG_1,	  f_spellsuggest},
     {"split",		1, 3, FEARG_1,	  f_split},
 #ifdef FEAT_FLOAT
     {"sqrt",		1, 1, FEARG_1,	  f_sqrt},
     {"str2float",	1, 1, FEARG_1,	  f_str2float},
 #endif
     {"str2list",	1, 2, FEARG_1,	  f_str2list},
-    {"str2nr",		1, 2, 0,	  f_str2nr},
-    {"strcharpart",	2, 3, 0,	  f_strcharpart},
-    {"strchars",	1, 2, 0,	  f_strchars},
-    {"strdisplaywidth",	1, 2, 0,	  f_strdisplaywidth},
+    {"str2nr",		1, 2, FEARG_1,	  f_str2nr},
+    {"strcharpart",	2, 3, FEARG_1,	  f_strcharpart},
+    {"strchars",	1, 2, FEARG_1,	  f_strchars},
+    {"strdisplaywidth",	1, 2, FEARG_1,	  f_strdisplaywidth},
 #ifdef HAVE_STRFTIME
-    {"strftime",	1, 2, 0,	  f_strftime},
-#endif
-    {"strgetchar",	2, 2, 0,	  f_strgetchar},
-    {"stridx",		2, 3, 0,	  f_stridx},
+    {"strftime",	1, 2, FEARG_1,	  f_strftime},
+#endif
+    {"strgetchar",	2, 2, FEARG_1,	  f_strgetchar},
+    {"stridx",		2, 3, FEARG_1,	  f_stridx},
     {"string",		1, 1, FEARG_1,	  f_string},
     {"strlen",		1, 1, FEARG_1,	  f_strlen},
-    {"strpart",		2, 3, 0,	  f_strpart},
-    {"strridx",		2, 3, 0,	  f_strridx},
+    {"strpart",		2, 3, FEARG_1,	  f_strpart},
+    {"strridx",		2, 3, FEARG_1,	  f_strridx},
     {"strtrans",	1, 1, FEARG_1,	  f_strtrans},
     {"strwidth",	1, 1, FEARG_1,	  f_strwidth},
-    {"submatch",	1, 2, 0,	  f_submatch},
+    {"submatch",	1, 2, FEARG_1,	  f_submatch},
     {"substitute",	4, 4, FEARG_1,	  f_substitute},
-    {"swapinfo",	1, 1, 0,	  f_swapinfo},
-    {"swapname",	1, 1, 0,	  f_swapname},
+    {"swapinfo",	1, 1, FEARG_1,	  f_swapinfo},
+    {"swapname",	1, 1, FEARG_1,	  f_swapname},
     {"synID",		3, 3, 0,	  f_synID},
     {"synIDattr",	2, 3, FEARG_1,	  f_synIDattr},
     {"synIDtrans",	1, 1, FEARG_1,	  f_synIDtrans},