~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_yacc.yy

  • Committer: Mark Atwood
  • Date: 2011-08-12 04:08:33 UTC
  • mfrom: (2385.2.17 refactor5)
  • Revision ID: me@mark.atwood.name-20110812040833-u6j85nc6ahuc0dtz
mergeĀ lp:~olafvdspek/drizzle/refactor5

Show diffs side-by-side

added added

removed removed

Lines of Context:
3077
3077
          }
3078
3078
          opt_udf_expr_list ')'
3079
3079
          {
3080
 
            Create_func *builder;
3081
3080
            Item *item= NULL;
3082
3081
 
3083
3082
            /*
3089
3088
 
3090
3089
              This will be revised with WL#2128 (SQL PATH)
3091
3090
            */
3092
 
            builder= find_native_function_builder($1);
3093
 
            if (builder)
 
3091
            if (Create_func* builder= find_native_function_builder($1))
3094
3092
            {
3095
3093
              item= builder->create(YYSession, $1, $4);
3096
3094
            }
3097
 
            else
 
3095
            else if (const plugin::Function* udf= $<udf>3) /* Retrieving the result of service::Function::get */
3098
3096
            {
3099
 
              /* Retrieving the result of service::Function::get */
3100
 
              const plugin::Function *udf= $<udf>3;
3101
 
              if (udf)
3102
 
              {
3103
 
                item= Create_udf_func::s_singleton.create(YYSession, udf, $4);
3104
 
              } else {
3105
 
                /* fix for bug 250065, from Andrew Garner <muzazzi@gmail.com> */
3106
 
                my_error(ER_SP_DOES_NOT_EXIST, MYF(0), "FUNCTION", $1.str);
3107
 
              }
 
3097
                  item= Create_udf_func::s_singleton.create(YYSession, udf, $4);
 
3098
            } 
 
3099
                        else 
 
3100
                        {
 
3101
              /* fix for bug 250065, from Andrew Garner <muzazzi@gmail.com> */
 
3102
              my_error(ER_SP_DOES_NOT_EXIST, MYF(0), "FUNCTION", $1.str);
3108
3103
            }
3109
3104
 
3110
 
            if (! ($$= item))
 
3105
            if (not ($$= item))
3111
3106
            {
3112
3107
              DRIZZLE_YYABORT;
3113
3108
            }