diff src/evalfunc.c @ 18033:049a7481d737 v8.1.2012

patch 8.1.2012: more functions can be used as methods Commit: https://github.com/vim/vim/commit/7ee80f766130f22598c928415c92ec612a8f18cf Author: Bram Moolenaar <Bram@vim.org> Date: Sun Sep 8 20:55:06 2019 +0200 patch 8.1.2012: more functions can be used as methods Problem: More functions can be used as methods. Solution: Make terminal functions usable as a method. Fix term_getattr().
author Bram Moolenaar <Bram@vim.org>
date Sun, 08 Sep 2019 21:00:03 +0200
parents 8a2fb21c23c0
children 11dca9732a48
line wrap: on
line diff
--- a/src/evalfunc.c
+++ b/src/evalfunc.c
@@ -765,33 +765,33 @@ static funcentry_T global_functions[] =
 #endif
     {"tempname",	0, 0, 0,	  f_tempname},
 #ifdef FEAT_TERMINAL
-    {"term_dumpdiff",	2, 3, 0,	  f_term_dumpdiff},
-    {"term_dumpload",	1, 2, 0,	  f_term_dumpload},
-    {"term_dumpwrite",	2, 3, 0,	  f_term_dumpwrite},
-    {"term_getaltscreen", 1, 1, 0,	  f_term_getaltscreen},
+    {"term_dumpdiff",	2, 3, FEARG_1,	  f_term_dumpdiff},
+    {"term_dumpload",	1, 2, FEARG_1,	  f_term_dumpload},
+    {"term_dumpwrite",	2, 3, FEARG_2,	  f_term_dumpwrite},
+    {"term_getaltscreen", 1, 1, FEARG_1,  f_term_getaltscreen},
 # if defined(FEAT_GUI) || defined(FEAT_TERMGUICOLORS)
-    {"term_getansicolors", 1, 1, 0,	  f_term_getansicolors},
+    {"term_getansicolors", 1, 1, FEARG_1, f_term_getansicolors},
 # endif
-    {"term_getattr",	2, 2, 0,	  f_term_getattr},
-    {"term_getcursor",	1, 1, 0,	  f_term_getcursor},
-    {"term_getjob",	1, 1, 0,	  f_term_getjob},
-    {"term_getline",	2, 2, 0,	  f_term_getline},
-    {"term_getscrolled", 1, 1, 0,	  f_term_getscrolled},
-    {"term_getsize",	1, 1, 0,	  f_term_getsize},
-    {"term_getstatus",	1, 1, 0,	  f_term_getstatus},
-    {"term_gettitle",	1, 1, 0,	  f_term_gettitle},
-    {"term_gettty",	1, 2, 0,	  f_term_gettty},
+    {"term_getattr",	2, 2, FEARG_1,	  f_term_getattr},
+    {"term_getcursor",	1, 1, FEARG_1,	  f_term_getcursor},
+    {"term_getjob",	1, 1, FEARG_1,	  f_term_getjob},
+    {"term_getline",	2, 2, FEARG_1,	  f_term_getline},
+    {"term_getscrolled", 1, 1, FEARG_1,	  f_term_getscrolled},
+    {"term_getsize",	1, 1, FEARG_1,	  f_term_getsize},
+    {"term_getstatus",	1, 1, FEARG_1,	  f_term_getstatus},
+    {"term_gettitle",	1, 1, FEARG_1,	  f_term_gettitle},
+    {"term_gettty",	1, 2, FEARG_1,	  f_term_gettty},
     {"term_list",	0, 0, 0,	  f_term_list},
-    {"term_scrape",	2, 2, 0,	  f_term_scrape},
-    {"term_sendkeys",	2, 2, 0,	  f_term_sendkeys},
+    {"term_scrape",	2, 2, FEARG_1,	  f_term_scrape},
+    {"term_sendkeys",	2, 2, FEARG_1,	  f_term_sendkeys},
 # if defined(FEAT_GUI) || defined(FEAT_TERMGUICOLORS)
-    {"term_setansicolors", 2, 2, 0,	  f_term_setansicolors},
+    {"term_setansicolors", 2, 2, FEARG_1, f_term_setansicolors},
 # endif
-    {"term_setkill",	2, 2, 0,	  f_term_setkill},
-    {"term_setrestore",	2, 2, 0,	  f_term_setrestore},
-    {"term_setsize",	3, 3, 0,	  f_term_setsize},
-    {"term_start",	1, 2, 0,	  f_term_start},
-    {"term_wait",	1, 2, 0,	  f_term_wait},
+    {"term_setkill",	2, 2, FEARG_1,	  f_term_setkill},
+    {"term_setrestore",	2, 2, FEARG_1,	  f_term_setrestore},
+    {"term_setsize",	3, 3, FEARG_1,	  f_term_setsize},
+    {"term_start",	1, 2, FEARG_1,	  f_term_start},
+    {"term_wait",	1, 2, FEARG_1,	  f_term_wait},
 #endif
     {"test_alloc_fail",	3, 3, FEARG_1,	  f_test_alloc_fail},
     {"test_autochdir",	0, 0, 0,	  f_test_autochdir},