mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-04-19 14:51:13 -03:00
Remove some unsued macros and a template
This commit is contained in:
@@ -1080,13 +1080,6 @@ struct populator_t {
|
||||
node.accept(*this);
|
||||
}
|
||||
|
||||
template <typename Node>
|
||||
void visit_pointer_field(Node *&node) {
|
||||
// This field is a pointer embedding of an ast node.
|
||||
// Allocate and populate it.
|
||||
node = allocate_visit<Node>();
|
||||
}
|
||||
|
||||
// Overload for token fields.
|
||||
template <parse_token_type_t... TokTypes>
|
||||
void visit_node_field(token_t<TokTypes...> &token) {
|
||||
|
||||
@@ -71,8 +71,6 @@ static const struct woption long_options[] = {
|
||||
{L"help", no_argument, nullptr, 'h'}, {nullptr, 0, nullptr, 0}};
|
||||
|
||||
// Hint for invalid path operation with a colon.
|
||||
#define BUILTIN_SET_PATH_ERROR _(L"%ls: Warning: $%ls entry \"%ls\" is not valid (%s)\n")
|
||||
#define BUILTIN_SET_PATH_HINT _(L"%ls: Did you mean 'set %ls $%ls %ls'?\n")
|
||||
#define BUILTIN_SET_MISMATCHED_ARGS _(L"%ls: You provided %d indexes but %d values\n")
|
||||
#define BUILTIN_SET_ERASE_NO_VAR _(L"%ls: Erase needs a variable name\n")
|
||||
#define BUILTIN_SET_ARRAY_BOUNDS_ERR _(L"%ls: Array index out of bounds\n")
|
||||
|
||||
@@ -37,8 +37,6 @@
|
||||
#include "wildcard.h"
|
||||
#include "wutil.h" // IWYU pragma: keep
|
||||
|
||||
#define CURSOR_POSITION_INVALID static_cast<size_t>(-1)
|
||||
|
||||
static const wchar_t *get_highlight_var_name(highlight_role_t role) {
|
||||
switch (role) {
|
||||
case highlight_role_t::normal:
|
||||
|
||||
@@ -58,7 +58,6 @@ const enum_map<parse_token_type_t> token_enum_map[] = {
|
||||
{parse_token_type_t::terminate, L"parse_token_type_t::terminate"},
|
||||
{parse_token_type_t::invalid, L"parse_token_type_t::invalid"},
|
||||
{parse_token_type_t::invalid, nullptr}};
|
||||
#define token_enum_map_len (sizeof token_enum_map / sizeof *token_enum_map)
|
||||
|
||||
// IMPORTANT: If the following enum is modified you must update the corresponding keyword_enum_map
|
||||
// array below.
|
||||
|
||||
@@ -32,9 +32,6 @@
|
||||
|
||||
class io_chain_t;
|
||||
|
||||
/// Error for evaluating in illegal scope.
|
||||
#define INVALID_SCOPE_ERR_MSG _(L"Tried to evaluate commands using invalid block type '%ls'")
|
||||
|
||||
/// While block description.
|
||||
#define WHILE_BLOCK N_(L"'while' block")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user