refactor: change remaining sourcing_name/sourcing_lnum to exestack

Co-Authored-By: VVKot <volodymyr.kot.ua@gmail.com>
This commit is contained in:
zeertzjq
2022-08-13 16:07:05 +08:00
parent f52c236c5b
commit ded2925b40
6 changed files with 31 additions and 44 deletions

View File

@@ -8,20 +8,20 @@
#include "nvim/ex_cmds_defs.h"
#include "nvim/ex_eval_defs.h"
/// Entry in the execution stack "exestack".
typedef enum {
ETYPE_TOP, // toplevel
ETYPE_SCRIPT, // sourcing script, use es_info.sctx
ETYPE_UFUNC, // user function, use es_info.ufunc
ETYPE_AUCMD, // autocomand, use es_info.aucmd
ETYPE_MODELINE, // modeline, use es_info.sctx
ETYPE_EXCEPT, // exception, use es_info.exception
ETYPE_ARGS, // command line argument
ETYPE_ENV, // environment variable
ETYPE_INTERNAL, // internal operation
ETYPE_SPELL, // loading spell file
ETYPE_TOP, ///< toplevel
ETYPE_SCRIPT, ///< sourcing script, use es_info.sctx
ETYPE_UFUNC, ///< user function, use es_info.ufunc
ETYPE_AUCMD, ///< autocomand, use es_info.aucmd
ETYPE_MODELINE, ///< modeline, use es_info.sctx
ETYPE_EXCEPT, ///< exception, use es_info.exception
ETYPE_ARGS, ///< command line argument
ETYPE_ENV, ///< environment variable
ETYPE_INTERNAL, ///< internal operation
ETYPE_SPELL, ///< loading spell file
} etype_T;
/// Entry in the execution stack "exestack".
typedef struct {
linenr_T es_lnum; ///< replaces "sourcing_lnum"
char *es_name; ///< replaces "sourcing_name"