diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-11-30 22:48:32 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-11-30 22:48:32 +0100 |
commit | 07dc18ffa4e7ed202f219fe2fd3d6f58246f71f9 (patch) | |
tree | cff51538c1e68b208e06b278f4b675dbe00380a0 /src/ex_cmds.h | |
parent | 01a060da74b756b161e595b39a7877cb7612120a (diff) |
patch 8.1.0553: it is not easy to edit a script that was sourcedv8.1.0553
Problem: It is not easy to edit a script that was sourced.
Solution: Add a count to ":scriptnames", so that ":script 40" edits the
script with script ID 40.
Diffstat (limited to 'src/ex_cmds.h')
-rw-r--r-- | src/ex_cmds.h | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/ex_cmds.h b/src/ex_cmds.h index c5e0bf4495..335871a01b 100644 --- a/src/ex_cmds.h +++ b/src/ex_cmds.h @@ -62,15 +62,15 @@ #define FILE1 (FILES | NOSPC) /* 1 file allowed, defaults to current file */ /* values for cmd_addr_type */ -#define ADDR_LINES 0 -#define ADDR_WINDOWS 1 -#define ADDR_ARGUMENTS 2 -#define ADDR_LOADED_BUFFERS 3 -#define ADDR_BUFFERS 4 -#define ADDR_TABS 5 -#define ADDR_TABS_RELATIVE 6 /* Tab page that only relative */ -#define ADDR_QUICKFIX 7 -#define ADDR_OTHER 99 +#define ADDR_LINES 0 // buffer line numbers +#define ADDR_WINDOWS 1 // window number +#define ADDR_ARGUMENTS 2 // argument number +#define ADDR_LOADED_BUFFERS 3 // buffer number of loaded buffer +#define ADDR_BUFFERS 4 // buffer number +#define ADDR_TABS 5 // tab page number +#define ADDR_TABS_RELATIVE 6 // Tab page that only relative +#define ADDR_QUICKFIX 7 // quickfix list entry number +#define ADDR_OTHER 99 // something else #ifndef DO_DECLARE_EXCMD typedef struct exarg exarg_T; @@ -1260,8 +1260,8 @@ EX(CMD_sbrewind, "sbrewind", ex_brewind, EDITCMD|TRLBAR, ADDR_LINES), EX(CMD_scriptnames, "scriptnames", ex_scriptnames, - TRLBAR|CMDWIN, - ADDR_LINES), + BANG|RANGE|NOTADR|COUNT|TRLBAR|CMDWIN, + ADDR_OTHER), EX(CMD_scriptencoding, "scriptencoding", ex_scriptencoding, WORD1|TRLBAR|CMDWIN, ADDR_LINES), |