Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-21023

Move LEX methods and related functions from sql_yacc.yy to sql_lex.cc

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Fix Version/s: 10.5.0
    • Component/s: Parser
    • Labels:
      None

      Description

      sql_yacc.yy contains implementations of a number of LEX methods and public functions:

      int LEX::case_stmt_action_expr(Item* expr);
       
      int LEX::case_stmt_action_when(Item *when, bool simple);
      int LEX::case_stmt_action_then();
       
      bool LEX::set_system_variable(enum enum_var_type var_type,
                                    sys_var *sysvar,
                                    const Lex_ident_sys_st *base_name,
                                    Item *val);
       
      bool LEX::set_trigger_new_row(const LEX_CSTRING *name, Item *val)
       
      Item_splocal *LEX::create_item_for_sp_var(const Lex_ident_cli_st *cname,
                                                sp_variable *spvar);
       
      Item* handle_sql2003_note184_exception(THD *thd, Item* left, bool equal,
                                             Item *expr)
       
      bool sp_create_assignment_lex(THD *thd, const char *pos)
       
      bool sp_create_assignment_instr(THD *thd, bool no_lookahead,
                                      bool need_set_keyword)
       
      void LEX::add_key_to_list(LEX_CSTRING *field_name,
                                enum Key::Keytype type, bool check_exists)
       
      bool LEX::add_alter_list(const char *name, Virtual_column_info *expr,
                               bool exists)
       
      void LEX::init_last_field(Column_definition *field,
                                const LEX_CSTRING *field_name,
                                const CHARSET_INFO *cs)
       
      bool LEX::set_bincmp(CHARSET_INFO *cs, bool bin)
       
      Virtual_column_info *add_virtual_expression(THD *thd, Item *expr);
      

      In order to unify sql_yacc.yy and sql_yacc_ora.yy easier, let's move these methods and functions to sql_lex.cc.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              bar Alexander Barkov
              Reporter:
              bar Alexander Barkov
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: