diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc index 9f69e7dee05..ab5bdc1e6fa 100644 --- a/sql/sql_lex.cc +++ b/sql/sql_lex.cc @@ -1770,7 +1770,7 @@ TABLE_LIST *st_select_lex_node::add_table_to_list (THD *thd, Table_ident *table, LEX_STRING *alias, ulong table_join_options, thr_lock_type flags, - List *hints, + List *hints, LEX_STRING *option) { return 0; @@ -2723,7 +2723,7 @@ void st_select_lex::set_index_hint_type(enum index_hint_type type, void st_select_lex::alloc_index_hints (THD *thd) { - index_hints= new (thd->mem_root) List(); + index_hints= new (thd->mem_root) List(); } @@ -2744,7 +2744,7 @@ void st_select_lex::alloc_index_hints (THD *thd) bool st_select_lex::add_index_hint (THD *thd, char *str, uint length) { return index_hints->push_front (new (thd->mem_root) - index_hint(current_index_hint_type, + Index_hint(current_index_hint_type, current_index_hint_clause, str, length)); } diff --git a/sql/sql_lex.h b/sql/sql_lex.h index 4ac59fbacde..6044f4f752e 100644 --- a/sql/sql_lex.h +++ b/sql/sql_lex.h @@ -236,7 +236,7 @@ typedef uchar index_clause_map; INDEX_HINT_MASK_ORDER) /* Single element of an USE/FORCE/IGNORE INDEX list specified as a SQL hint */ -class index_hint : public Sql_alloc +class Index_hint : public Sql_alloc { public: /* The type of the hint : USE/FORCE/IGNORE */ @@ -249,7 +249,7 @@ public: */ LEX_STRING key_name; - index_hint (enum index_hint_type type_arg, index_clause_map clause_arg, + Index_hint (enum index_hint_type type_arg, index_clause_map clause_arg, char *str, uint length) : type(type_arg), clause(clause_arg) { @@ -441,7 +441,7 @@ public: LEX_STRING *alias, ulong table_options, thr_lock_type flags= TL_UNLOCK, - List *hints= 0, + List *hints= 0, LEX_STRING *option= 0); virtual void set_lock_for_tables(thr_lock_type lock_type) {} @@ -719,7 +719,7 @@ public: LEX_STRING *alias, ulong table_options, thr_lock_type flags= TL_UNLOCK, - List *hints= 0, + List *hints= 0, LEX_STRING *option= 0); TABLE_LIST* get_table_list(); bool init_nested_join(THD *thd); @@ -779,9 +779,9 @@ public: /* make a list to hold index hints */ void alloc_index_hints (THD *thd); /* read and clear the index hints */ - List* pop_index_hints(void) + List* pop_index_hints(void) { - List *hints= index_hints; + List *hints= index_hints; index_hints= NULL; return hints; } @@ -793,7 +793,7 @@ private: enum index_hint_type current_index_hint_type; index_clause_map current_index_hint_clause; /* a list of USE/FORCE/IGNORE INDEX */ - List *index_hints; + List *index_hints; }; typedef class st_select_lex SELECT_LEX; diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc index f2a61b7f7c5..93887db88e1 100644 --- a/sql/sql_parse.cc +++ b/sql/sql_parse.cc @@ -5636,7 +5636,7 @@ TABLE_LIST *st_select_lex::add_table_to_list(THD *thd, LEX_STRING *alias, ulong table_options, thr_lock_type lock_type, - List *index_hints_arg, + List *index_hints_arg, LEX_STRING *option) { register TABLE_LIST *ptr; diff --git a/sql/table.cc b/sql/table.cc index 5ac43343934..2c4d18ca4ff 100644 --- a/sql/table.cc +++ b/sql/table.cc @@ -4642,11 +4642,11 @@ bool TABLE_LIST::process_index_hints(TABLE *table) key_map index_join[INDEX_HINT_FORCE + 1]; key_map index_order[INDEX_HINT_FORCE + 1]; key_map index_group[INDEX_HINT_FORCE + 1]; - index_hint *hint; + Index_hint *hint; int type; bool have_empty_use_join= FALSE, have_empty_use_order= FALSE, have_empty_use_group= FALSE; - List_iterator iter(*index_hints); + List_iterator iter(*index_hints); /* initialize temporary variables used to collect hints of each kind */ for (type= INDEX_HINT_IGNORE; type <= INDEX_HINT_FORCE; type++) diff --git a/sql/table.h b/sql/table.h index 494b74d564c..a276a9f32fd 100644 --- a/sql/table.h +++ b/sql/table.h @@ -754,7 +754,7 @@ public: (TABLE_LIST::join_using_fields != NULL) */ -class index_hint; +class Index_hint; struct TABLE_LIST { TABLE_LIST() {} /* Remove gcc warning */ @@ -826,7 +826,7 @@ struct TABLE_LIST */ TABLE_LIST *next_name_resolution_table; /* Index names in a "... JOIN ... USE/IGNORE INDEX ..." clause. */ - List *index_hints; + List *index_hints; TABLE *table; /* opened table */ uint table_id; /* table id (from binlog) for opened table */ /*