mirror of
https://github.com/neovim/neovim.git
synced 2025-10-17 07:16:09 +00:00
Remove long_u: ex_cmds_defs.h: Refactor long_u.
CommandDefinition.cmd_argt: long_u --> uint32_t.
This commit is contained in:
@@ -67,7 +67,7 @@ for i, cmd in ipairs(defs) do
|
||||
[%s] = {
|
||||
.cmd_name = (char_u *) "%s",
|
||||
.cmd_func = &%s,
|
||||
.cmd_argt = %uL
|
||||
.cmd_argt = %u
|
||||
}]], enumname, cmd.command, cmd.func, cmd.flags))
|
||||
end
|
||||
defsfile:write([[
|
||||
|
@@ -8,6 +8,7 @@
|
||||
#define NVIM_EX_CMDS_DEFS_H
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
|
||||
#include "nvim/pos.h" // for linenr_T
|
||||
#include "nvim/normal.h"
|
||||
@@ -59,13 +60,13 @@
|
||||
#define USECTRLV 0x2000 /* do not remove CTRL-V from argument */
|
||||
#define NOTADR 0x4000 /* number before command is not an address */
|
||||
#define EDITCMD 0x8000 /* allow "+command" argument */
|
||||
#define BUFNAME 0x10000L /* accepts buffer name */
|
||||
#define BUFUNL 0x20000L /* accepts unlisted buffer too */
|
||||
#define ARGOPT 0x40000L /* allow "++opt=val" argument */
|
||||
#define SBOXOK 0x80000L /* allowed in the sandbox */
|
||||
#define CMDWIN 0x100000L /* allowed in cmdline window */
|
||||
#define MODIFY 0x200000L /* forbidden in non-'modifiable' buffer */
|
||||
#define EXFLAGS 0x400000L /* allow flags after count in argument */
|
||||
#define BUFNAME 0x10000 /* accepts buffer name */
|
||||
#define BUFUNL 0x20000 /* accepts unlisted buffer too */
|
||||
#define ARGOPT 0x40000 /* allow "++opt=val" argument */
|
||||
#define SBOXOK 0x80000 /* allowed in the sandbox */
|
||||
#define CMDWIN 0x100000 /* allowed in cmdline window */
|
||||
#define MODIFY 0x200000 /* forbidden in non-'modifiable' buffer */
|
||||
#define EXFLAGS 0x400000 /* allow flags after count in argument */
|
||||
#define FILES (XFILE | EXTRA) /* multiple extra files allowed */
|
||||
#define WORD1 (EXTRA | NOSPC) /* one extra word allowed */
|
||||
#define FILE1 (FILES | NOSPC) /* 1 file allowed, defaults to current file */
|
||||
@@ -85,7 +86,7 @@ typedef char_u *(*LineGetter)(int, void *, int);
|
||||
typedef struct cmdname {
|
||||
char_u *cmd_name; ///< Name of the command.
|
||||
ex_func_T cmd_func; ///< Function with implementation of this command.
|
||||
long_u cmd_argt; ///< Relevant flags from the declared above.
|
||||
uint32_t cmd_argt; ///< Relevant flags from the declared above.
|
||||
} CommandDefinition;
|
||||
|
||||
/// Arguments used for Ex commands.
|
||||
|
Reference in New Issue
Block a user