~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_yacc.yy

  • Committer: Brian Aker
  • Date: 2009-02-05 10:59:21 UTC
  • Revision ID: brian@tangent.org-20090205105921-2r59encsosh9roww
More class adoption/method

Show diffs side-by-side

added added

removed removed

Lines of Context:
2799
2799
        | '*'
2800
2800
          {
2801
2801
            Session *session= YYSession;
2802
 
            if (add_item_to_list(session,
2803
 
                                 new Item_field(&session->lex->current_select->
2804
 
                                                context,
2805
 
                                                NULL, NULL, "*")))
 
2802
            if (session->add_item_to_list( new Item_field(&session->lex->current_select->
 
2803
                                                          context,
 
2804
                                                          NULL, NULL, "*")))
2806
2805
              DRIZZLE_YYABORT;
2807
2806
            (session->lex->current_select->with_wild)++;
2808
2807
          }
2813
2812
          {
2814
2813
            Session *session= YYSession;
2815
2814
 
2816
 
            if (add_item_to_list(session, $2))
 
2815
            if (session->add_item_to_list($2))
2817
2816
              DRIZZLE_YYABORT;
2818
2817
          }
2819
2818
        | remember_name expr remember_end select_alias
2821
2820
            Session *session= YYSession;
2822
2821
            assert($1 < $3);
2823
2822
 
2824
 
            if (add_item_to_list(session, $2))
 
2823
            if (session->add_item_to_list($2))
2825
2824
              DRIZZLE_YYABORT;
2826
2825
            if ($4.str)
2827
2826
            {
4288
4287
 
4289
4288
group_list:
4290
4289
          group_list ',' order_ident order_dir
4291
 
          { if (add_group_to_list(YYSession, $3,(bool) $4)) DRIZZLE_YYABORT; }
 
4290
          { if (YYSession->add_group_to_list($3,(bool) $4)) DRIZZLE_YYABORT; }
4292
4291
        | order_ident order_dir
4293
 
          { if (add_group_to_list(YYSession, $1,(bool) $2)) DRIZZLE_YYABORT; }
 
4292
          { if (YYSession->add_group_to_list($1,(bool) $2)) DRIZZLE_YYABORT; }
4294
4293
        ;
4295
4294
 
4296
4295
olap_opt:
4333
4332
          {
4334
4333
            Session *session= YYSession;
4335
4334
            bool ascending= ($2 == 1) ? true : false;
4336
 
            if (add_order_to_list(session, $1, ascending))
 
4335
            if (session->add_order_to_list($1, ascending))
4337
4336
              DRIZZLE_YYABORT;
4338
4337
          }
4339
4338
        ;
4384
4383
 
4385
4384
order_list:
4386
4385
          order_list ',' order_ident order_dir
4387
 
          { if (add_order_to_list(YYSession, $3,(bool) $4)) DRIZZLE_YYABORT; }
 
4386
          { if (YYSession->add_order_to_list($3,(bool) $4)) DRIZZLE_YYABORT; }
4388
4387
        | order_ident order_dir
4389
 
          { if (add_order_to_list(YYSession, $1,(bool) $2)) DRIZZLE_YYABORT; }
 
4388
          { if (YYSession->add_order_to_list($1,(bool) $2)) DRIZZLE_YYABORT; }
4390
4389
        ;
4391
4390
 
4392
4391
order_dir:
4843
4842
update_elem:
4844
4843
          simple_ident_nospvar equal expr_or_default
4845
4844
          {
4846
 
            if (add_item_to_list(YYSession, $1) || add_value_to_list(YYSession, $3))
 
4845
            if (YYSession->add_item_to_list($1) || YYSession->add_value_to_list($3))
4847
4846
              DRIZZLE_YYABORT;
4848
4847
          }
4849
4848
        ;