From 937da5dd7ebf7e164e81a1361fdd5239cc9b5201 Mon Sep 17 00:00:00 2001 From: Jakub Łuczyński Date: Mon, 10 Feb 2020 15:02:19 +0100 Subject: Removed redundant define --- src/nvim/viml/parser/expressions.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'src/nvim/viml/parser') diff --git a/src/nvim/viml/parser/expressions.c b/src/nvim/viml/parser/expressions.c index b4a0f57e99..b77b80a5f3 100644 --- a/src/nvim/viml/parser/expressions.c +++ b/src/nvim/viml/parser/expressions.c @@ -133,9 +133,6 @@ typedef enum { # include "viml/parser/expressions.c.generated.h" #endif -/// Character used as a separator in autoload function/variable names. -#define AUTOLOAD_CHAR '#' - /// Scale number by a given factor /// /// Used to apply exponent to a number. Idea taken from uClibc. -- cgit From b87b4a61476bb65e9200bd2ee93b8a98ca4db84e Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Mon, 17 Feb 2020 17:17:37 +0100 Subject: nvim:viml: Fix enum declaration of ExprParserFlags Instead of declaring an enum, this creates a global variable. As gcc10 uses -fno-common by default, global variables declared with the same name more than once is not allowed anymore revealing this issue. Each time this header is included, we define the enum name as a global variable. See also https://bugzilla.redhat.com/show_bug.cgi?id=1799680 --- src/nvim/viml/parser/expressions.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/nvim/viml/parser') diff --git a/src/nvim/viml/parser/expressions.h b/src/nvim/viml/parser/expressions.h index 23e172da75..838a742271 100644 --- a/src/nvim/viml/parser/expressions.h +++ b/src/nvim/viml/parser/expressions.h @@ -326,7 +326,7 @@ struct expr_ast_node { } data; }; -enum { +enum ExprParserFlags { /// Allow multiple expressions in a row: e.g. for :echo /// /// Parser will still parse only one of them though. @@ -345,7 +345,7 @@ enum { // viml_expressions_parser.c, nvim_parse_expression() flags parsing // alongside with its documentation and flag sets in check_parsing() // function in expressions parser functional and unit tests. -} ExprParserFlags; +}; /// AST error definition typedef struct { -- cgit