diff options
author | Eugene Kosov <claprix@yandex.ru> | 2019-06-24 19:38:00 +0300 |
---|---|---|
committer | Eugene Kosov <claprix@yandex.ru> | 2019-06-25 13:21:36 +0300 |
commit | d36c107a6b7f9e9bc9425072f2ac13afd2334069 (patch) | |
tree | f2789ec42ae3419e7633aeb08b5a8a27fd703329 /client | |
parent | d78145459f79d02438e0d57fe8acaff757018c97 (diff) | |
download | mariadb-git-d36c107a6b7f9e9bc9425072f2ac13afd2334069.tar.gz |
imporve clang build
cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_BUILD_TYPE=Debug
Maintainer mode makes all warnings errors. This patch fix warnings. Mostly about
deprecated `register` keyword.
Too much warnings came from Mroonga and I gave up on it.
Diffstat (limited to 'client')
-rw-r--r-- | client/mysql.cc | 2 | ||||
-rw-r--r-- | client/mysqltest.cc | 16 |
2 files changed, 9 insertions, 9 deletions
diff --git a/client/mysql.cc b/client/mysql.cc index f938c8f00ff..31c1d443607 100644 --- a/client/mysql.cc +++ b/client/mysql.cc @@ -3128,7 +3128,7 @@ static int com_help(String *buffer __attribute__((unused)), char *line __attribute__((unused))) { - reg1 int i, j; + int i, j; char * help_arg= strchr(line,' '), buff[32], *end; if (help_arg) { diff --git a/client/mysqltest.cc b/client/mysqltest.cc index 051e7fbef02..1f17f75e1b8 100644 --- a/client/mysqltest.cc +++ b/client/mysqltest.cc @@ -1044,8 +1044,8 @@ void do_eval(DYNAMIC_STRING *query_eval, const char *query, const char *query_end, my_bool pass_through_escape_chars) { const char *p; - register char c, next_c; - register int escaped = 0; + char c, next_c; + int escaped = 0; VAR *v; DBUG_ENTER("do_eval"); @@ -2341,7 +2341,7 @@ C_MODE_START static uchar *get_var_key(const uchar* var, size_t *len, my_bool __attribute__((unused)) t) { - register char* key; + char* key; key = ((VAR*)var)->name; *len = ((VAR*)var)->name_len; return (uchar*)key; @@ -9900,7 +9900,7 @@ typedef struct st_pointer_array { /* when using array-strings */ struct st_replace *init_replace(char * *from, char * *to, uint count, char * word_end_chars); -int insert_pointer_name(reg1 POINTER_ARRAY *pa,char * name); +int insert_pointer_name(POINTER_ARRAY *pa,char * name); void free_pointer_array(POINTER_ARRAY *pa); /* @@ -9984,8 +9984,8 @@ void replace_strings_append(REPLACE *rep, DYNAMIC_STRING* ds, const char *str, int len __attribute__((unused))) { - reg1 REPLACE *rep_pos; - reg2 REPLACE_STRING *rep_str; + REPLACE *rep_pos; + REPLACE_STRING *rep_str; const char *start, *from; DBUG_ENTER("replace_strings_append"); @@ -10891,7 +10891,7 @@ void internal_clear_bit(REP_SET *set, uint bit) void or_bits(REP_SET *to,REP_SET *from) { - reg1 uint i; + uint i; for (i=0 ; i < to->size_of_bits ; i++) to->bits[i]|=from->bits[i]; return; @@ -10993,7 +10993,7 @@ uint end_of_word(char * pos) #define PC_MALLOC 256 /* Bytes for pointers */ #define PS_MALLOC 512 /* Bytes for data */ -int insert_pointer_name(reg1 POINTER_ARRAY *pa,char * name) +int insert_pointer_name(POINTER_ARRAY *pa,char * name) { uint i,length,old_count; uchar *new_pos; |