diff options
author | Daniel Black <daniel@mariadb.org> | 2021-02-25 13:16:10 +1100 |
---|---|---|
committer | Daniel Black <daniel@mariadb.org> | 2021-02-25 13:16:10 +1100 |
commit | 36810342d51d9394f4739fac85618d44766aaeed (patch) | |
tree | 915ec1b0473cf155d44f7874d7b1792de659f5a7 /sql/sql_lex.cc | |
parent | d1eeb4b83932660f8c8170a861734076bb6af546 (diff) | |
parent | 3e2afcb3f409802d3cd7a713aea0dab0bfde6f48 (diff) | |
download | mariadb-git-36810342d51d9394f4739fac85618d44766aaeed.tar.gz |
Merge branch '10.3' into 10.4
Diffstat (limited to 'sql/sql_lex.cc')
-rw-r--r-- | sql/sql_lex.cc | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc index 6aec301bedc..73cbcf569f5 100644 --- a/sql/sql_lex.cc +++ b/sql/sql_lex.cc @@ -2530,6 +2530,8 @@ void st_select_lex_node::add_slave(st_select_lex_node *slave_arg) { slave= slave_arg; slave_arg->master= this; + slave->prev= &master->slave; + slave->next= 0; } } @@ -2552,6 +2554,27 @@ void st_select_lex_node::link_chain_down(st_select_lex_node *first) } /* + @brief + Substitute this node in select tree for a newly creates node + + @param subst the node to substitute for + + @details + The function substitute this node in the select tree for a newly + created node subst. This node is just removed from the tree but all + its link fields and the attached sub-tree remain untouched. +*/ + +void st_select_lex_node::substitute_in_tree(st_select_lex_node *subst) +{ + if ((subst->next= next)) + next->prev= &subst->next; + subst->prev= prev; + (*prev)= subst; + subst->master= master; +} + +/* include on level down (but do not link) SYNOPSYS |