(file) Return to CQLYACC.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / CQL

Diff for /pegasus/src/Pegasus/CQL/CQLYACC.cpp between version 1.7 and 1.8

version 1.7, 2004/12/11 18:54:02 version 1.8, 2005/01/10 16:55:25
Line 72 
Line 72 
 int chain_state; int chain_state;
 CQLFactory _factory = CQLFactory(); CQLFactory _factory = CQLFactory();
 extern int CQL_error(const char *err); extern int CQL_error(const char *err);
   
 PEGASUS_NAMESPACE_BEGIN PEGASUS_NAMESPACE_BEGIN
  
 extern CQLParserState* globalParserState; extern CQLParserState* globalParserState;
 Array<CQLPredicate> _arglist; Array<CQLPredicate> _arglist;
   
   enum CQLType { Id, CId, Val, Func, Fact, Trm, Expr, SPred, Pred, Str };
   
   typedef struct CQLObjPtr {
           void* _ptr;
                     CQLType type;
   } CQLOBJPTR;
   
   Array<CQLObjPtr> _ptrs;
   CQLOBJPTR _ObjPtr;
   
   void cleanup(){
           for(Uint32 i = 0; i < _ptrs.size(); i++){
             if(_ptrs[i]._ptr){
                   switch(_ptrs[i].type){
                           case Id:
                                           delete (CQLIdentifier*)_ptrs[i]._ptr;
                                           break;
                           case CId:
                                           delete (CQLChainedIdentifier*)_ptrs[i]._ptr;
                                           break;
                           case Val:
                                           delete (CQLValue*)_ptrs[i]._ptr;
                                           break;
                           case Func:
                                           delete (CQLFunction*)_ptrs[i]._ptr;
                                           break;
                           case Fact:
                                           delete (CQLFactor*)_ptrs[i]._ptr;
                                           break;
                           case Trm:
                                           delete (CQLTerm*)_ptrs[i]._ptr;
                                           break;
                           case Expr:
                                           delete (CQLExpression*)_ptrs[i]._ptr;
                                           break;
                           case SPred:
                                           delete (CQLSimplePredicate*)_ptrs[i]._ptr;
                                           break;
                           case Pred:
                                           delete (CQLPredicate*)_ptrs[i]._ptr;
                                           break;
                           case Str:
                                           delete (String*)_ptrs[i]._ptr;
                   }
             }
           }
           _ptrs.clear();
      _factory.cleanup();
      _factory = CQLFactory();
   }
   
 PEGASUS_NAMESPACE_END PEGASUS_NAMESPACE_END
  
  
 #line 42 "CQL.y"  #line 95 "CQL.y"
 typedef union { typedef union {
    char * strValue;    char * strValue;
    int lineno;    int lineno;
Line 98 
Line 151 
    CQLExpression * _expression;    CQLExpression * _expression;
    void * _node;    void * _node;
 } YYSTYPE; } YYSTYPE;
 #line 102 "y.tab.c"  #line 155 "y.tab.c"
 #define YYERRCODE 256 #define YYERRCODE 256
 #define IDENTIFIER 257 #define IDENTIFIER 257
 #define STRING_LITERAL 258 #define STRING_LITERAL 258
Line 454 
Line 507 
 short *yysslim; short *yysslim;
 YYSTYPE *yyvs; YYSTYPE *yyvs;
 int yystacksize; int yystacksize;
 #line 1193 "CQL.y"  #line 1297 "CQL.y"
  
 /*int yyerror(char * err){yyclearin; yyerrok;throw Exception(String(err));return 1;}*/ /*int yyerror(char * err){yyclearin; yyerrok;throw Exception(String(err));return 1;}*/
 #line 461 "y.tab.c"  #line 514 "y.tab.c"
 /* allocate initial stack or double stack size, up to YYMAXDEPTH */ /* allocate initial stack or double stack size, up to YYMAXDEPTH */
 static int yygrowstack() static int yygrowstack()
 { {
Line 653 
Line 706 
     switch (yyn)     switch (yyn)
     {     {
 case 1: case 1:
 #line 172 "CQL.y"  #line 225 "CQL.y"
 { {
                  globalParserState->currentRule = "identifier";                  globalParserState->currentRule = "identifier";
                  sprintf(msg,"BISON::identifier\n");                  sprintf(msg,"BISON::identifier\n");
                  printf_(msg);                  printf_(msg);
  
                  yyval._identifier = new CQLIdentifier(String(CQL_lval.strValue));                  yyval._identifier = new CQLIdentifier(String(CQL_lval.strValue));
                                             _ObjPtr._ptr = yyval._identifier;
                                             _ObjPtr.type = Id;
                                             _ptrs.append(_ObjPtr);
              }              }
 break; break;
 case 2: case 2:
 #line 182 "CQL.y"  #line 238 "CQL.y"
 { {
                  globalParserState->currentRule = "class_name";                  globalParserState->currentRule = "class_name";
                  sprintf(msg,"BISON::class_name = %s\n", (const char *)(yyvsp[0]._identifier->getName().getString().getCString()));                  sprintf(msg,"BISON::class_name = %s\n", (const char *)(yyvsp[0]._identifier->getName().getString().getCString()));
Line 672 
Line 728 
              }              }
 break; break;
 case 3: case 3:
 #line 191 "CQL.y"  #line 247 "CQL.y"
 { {
                 globalParserState->currentRule = "class_path";                 globalParserState->currentRule = "class_path";
                  sprintf(msg,"BISON::class_path\n");                  sprintf(msg,"BISON::class_path\n");
Line 681 
Line 737 
              }              }
 break; break;
 case 4: case 4:
 #line 210 "CQL.y"  #line 266 "CQL.y"
 { {
                         /*                         /*
                            SCOPED_PROPERTY can be:                            SCOPED_PROPERTY can be:
Line 696 
Line 752 
  
                         String tmp(CQL_lval.strValue);                         String tmp(CQL_lval.strValue);
                         yyval._identifier = new CQLIdentifier(tmp);                         yyval._identifier = new CQLIdentifier(tmp);
                                                           _ObjPtr._ptr = yyval._identifier;
                                   _ObjPtr.type = Id;
                                   _ptrs.append(_ObjPtr);
                   }                   }
 break; break;
 case 5: case 5:
 #line 229 "CQL.y"  #line 288 "CQL.y"
 { {
                 /*                 /*
                    We make sure the literal is valid UTF8, then make a String                    We make sure the literal is valid UTF8, then make a String
Line 710 
Line 769 
  
                 if(isUTF8Str(CQL_lval.strValue)){                 if(isUTF8Str(CQL_lval.strValue)){
                      yyval._string = new String(CQL_lval.strValue);                      yyval._string = new String(CQL_lval.strValue);
                             _ObjPtr._ptr = yyval._string;
              _ObjPtr.type = Str;
              _ptrs.append(_ObjPtr);
                 }else{                 }else{
                     sprintf(msg,"BISON::literal_string-> BAD UTF\n");                     sprintf(msg,"BISON::literal_string-> BAD UTF\n");
                     printf_(msg);                     printf_(msg);
                            cleanup();
                     throw CQLSyntaxErrorException(                     throw CQLSyntaxErrorException(
                                         MessageLoaderParms(String("CQL.CQL_y.BAD_UTF8"),                                         MessageLoaderParms(String("CQL.CQL_y.BAD_UTF8"),
                                                            String("Bad UTF8 encountered parsing rule $0 in position $1."),                                                            String("Bad UTF8 encountered parsing rule $0 in position $1."),
Line 723 
Line 786 
              }              }
 break; break;
 case 6: case 6:
 #line 254 "CQL.y"  #line 317 "CQL.y"
 { {
                    globalParserState->currentRule = "binary_value->BINARY";                    globalParserState->currentRule = "binary_value->BINARY";
                    sprintf(msg,"BISON::binary_value-> %s\n",CQL_lval.strValue);                    sprintf(msg,"BISON::binary_value-> %s\n",CQL_lval.strValue);
                    printf_(msg);                    printf_(msg);
  
                    yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Binary);                    yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Binary);
                                                    _ObjPtr._ptr = yyval._value;
                      _ObjPtr.type = Val;
                      _ptrs.append(_ObjPtr);
                }                }
 break; break;
 case 7: case 7:
 #line 262 "CQL.y"  #line 328 "CQL.y"
 { {
                    globalParserState->currentRule = "binary_value->NEGATIVE_BINARY";                    globalParserState->currentRule = "binary_value->NEGATIVE_BINARY";
                    sprintf(msg,"BISON::binary_value-> %s\n",CQL_lval.strValue);                    sprintf(msg,"BISON::binary_value-> %s\n",CQL_lval.strValue);
                    printf_(msg);                    printf_(msg);
  
                    yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Binary, false);                    yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Binary, false);
                                                    _ObjPtr._ptr = yyval._value;
                      _ObjPtr.type = Val;
                      _ptrs.append(_ObjPtr);
                }                }
 break; break;
 case 8: case 8:
 #line 273 "CQL.y"  #line 342 "CQL.y"
 { {
                 globalParserState->currentRule = "hex_value->HEXADECIMAL";                 globalParserState->currentRule = "hex_value->HEXADECIMAL";
                 sprintf(msg,"BISON::hex_value-> %s\n",CQL_lval.strValue);                 sprintf(msg,"BISON::hex_value-> %s\n",CQL_lval.strValue);
                 printf_(msg);                 printf_(msg);
  
                 yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Hex);                 yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Hex);
                                            _ObjPtr._ptr = yyval._value;
                   _ObjPtr.type = Val;
                   _ptrs.append(_ObjPtr);
             }             }
 break; break;
 case 9: case 9:
 #line 281 "CQL.y"  #line 353 "CQL.y"
 { {
                 globalParserState->currentRule = "hex_value->NEGATIVE_HEXADECIMAL";                 globalParserState->currentRule = "hex_value->NEGATIVE_HEXADECIMAL";
                 sprintf(msg,"BISON::hex_value-> %s\n",CQL_lval.strValue);                 sprintf(msg,"BISON::hex_value-> %s\n",CQL_lval.strValue);
                 printf_(msg);                 printf_(msg);
  
                 yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Hex, false);                 yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Hex, false);
                                       _ObjPtr._ptr = yyval._value;
                   _ObjPtr.type = Val;
                   _ptrs.append(_ObjPtr);
             }             }
 break; break;
 case 10: case 10:
 #line 292 "CQL.y"  #line 367 "CQL.y"
 { {
                     globalParserState->currentRule = "decimal_value->INTEGER";                     globalParserState->currentRule = "decimal_value->INTEGER";
                     sprintf(msg,"BISON::decimal_value-> %s\n",CQL_lval.strValue);                     sprintf(msg,"BISON::decimal_value-> %s\n",CQL_lval.strValue);
                     printf_(msg);                     printf_(msg);
  
                     yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Decimal);                     yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Decimal);
                                                     _ObjPtr._ptr = yyval._value;
                       _ObjPtr.type = Val;
                       _ptrs.append(_ObjPtr);
                 }                 }
 break; break;
 case 11: case 11:
 #line 300 "CQL.y"  #line 378 "CQL.y"
 { {
                     globalParserState->currentRule = "decimal_value->NEGATIVE_INTEGER";                     globalParserState->currentRule = "decimal_value->NEGATIVE_INTEGER";
                     sprintf(msg,"BISON::decimal_value-> %s\n",CQL_lval.strValue);                     sprintf(msg,"BISON::decimal_value-> %s\n",CQL_lval.strValue);
                     printf_(msg);                     printf_(msg);
  
                     yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Decimal, false);                     yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Decimal, false);
                                                     _ObjPtr._ptr = yyval._value;
                       _ObjPtr.type = Val;
                       _ptrs.append(_ObjPtr);
                 }                 }
 break; break;
 case 12: case 12:
 #line 311 "CQL.y"  #line 392 "CQL.y"
 { {
                  globalParserState->currentRule = "real_value->REAL";                  globalParserState->currentRule = "real_value->REAL";
                  sprintf(msg,"BISON::real_value-> %s\n",CQL_lval.strValue);                  sprintf(msg,"BISON::real_value-> %s\n",CQL_lval.strValue);
                  printf_(msg);                  printf_(msg);
                  yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Real);                  yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Real);
                                             _ObjPtr._ptr = yyval._value;
                    _ObjPtr.type = Val;
                    _ptrs.append(_ObjPtr);
              }              }
 break; break;
 case 13: case 13:
 #line 318 "CQL.y"  #line 402 "CQL.y"
 { {
                  globalParserState->currentRule = "real_value->NEGATIVE_REAL";                  globalParserState->currentRule = "real_value->NEGATIVE_REAL";
                  sprintf(msg,"BISON::real_value-> %s\n",CQL_lval.strValue);                  sprintf(msg,"BISON::real_value-> %s\n",CQL_lval.strValue);
                  printf_(msg);                  printf_(msg);
                  yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Real, false);                  yyval._value = new CQLValue(CQL_lval.strValue, CQLValue::Real, false);
                                             _ObjPtr._ptr = yyval._value;
                    _ObjPtr.type = Val;
                    _ptrs.append(_ObjPtr);
              }              }
 break; break;
 case 14: case 14:
 #line 328 "CQL.y"  #line 415 "CQL.y"
 { {
               globalParserState->currentRule = "literal->literal_string";               globalParserState->currentRule = "literal->literal_string";
               sprintf(msg,"BISON::literal->literal_string\n");               sprintf(msg,"BISON::literal->literal_string\n");
               printf_(msg);               printf_(msg);
               yyval._value = new CQLValue(*yyvsp[0]._string);               yyval._value = new CQLValue(*yyvsp[0]._string);
               delete yyvsp[0]._string;                                    _ObjPtr._ptr = yyval._value;
                 _ObjPtr.type = Val;
                 _ptrs.append(_ObjPtr);
           }           }
 break; break;
 case 15: case 15:
 #line 336 "CQL.y"  #line 425 "CQL.y"
 { {
               globalParserState->currentRule = "literal->decimal_value";               globalParserState->currentRule = "literal->decimal_value";
               sprintf(msg,"BISON::literal->decimal_value\n");               sprintf(msg,"BISON::literal->decimal_value\n");
Line 820 
Line 909 
           }           }
 break; break;
 case 16: case 16:
 #line 343 "CQL.y"  #line 432 "CQL.y"
 { {
               globalParserState->currentRule = "literal->binary_value";               globalParserState->currentRule = "literal->binary_value";
               sprintf(msg,"BISON::literal->binary_value\n");               sprintf(msg,"BISON::literal->binary_value\n");
Line 829 
Line 918 
           }           }
 break; break;
 case 17: case 17:
 #line 350 "CQL.y"  #line 439 "CQL.y"
 { {
               globalParserState->currentRule = "literal->hex_value";               globalParserState->currentRule = "literal->hex_value";
               sprintf(msg,"BISON::literal->hex_value\n");               sprintf(msg,"BISON::literal->hex_value\n");
Line 838 
Line 927 
           }           }
 break; break;
 case 18: case 18:
 #line 357 "CQL.y"  #line 446 "CQL.y"
 { {
               globalParserState->currentRule = "literal->real_value";               globalParserState->currentRule = "literal->real_value";
               sprintf(msg,"BISON::literal->real_value\n");               sprintf(msg,"BISON::literal->real_value\n");
Line 847 
Line 936 
           }           }
 break; break;
 case 19: case 19:
 #line 364 "CQL.y"  #line 453 "CQL.y"
 { {
               globalParserState->currentRule = "literal->_TRUE";               globalParserState->currentRule = "literal->_TRUE";
               sprintf(msg,"BISON::literal->_TRUE\n");               sprintf(msg,"BISON::literal->_TRUE\n");
               printf_(msg);               printf_(msg);
  
               yyval._value = new CQLValue(Boolean(true));               yyval._value = new CQLValue(Boolean(true));
                                     _ObjPtr._ptr = yyval._value;
                 _ObjPtr.type = Val;
                 _ptrs.append(_ObjPtr);
           }           }
 break; break;
 case 20: case 20:
 #line 372 "CQL.y"  #line 464 "CQL.y"
 { {
               globalParserState->currentRule = "literal->_FALSE";               globalParserState->currentRule = "literal->_FALSE";
               sprintf(msg,"BISON::literal->_FALSE\n");               sprintf(msg,"BISON::literal->_FALSE\n");
               printf_(msg);               printf_(msg);
  
               yyval._value = new CQLValue(Boolean(false));               yyval._value = new CQLValue(Boolean(false));
                                     _ObjPtr._ptr = yyval._value;
                 _ObjPtr.type = Val;
                 _ptrs.append(_ObjPtr);
           }           }
 break; break;
 case 21: case 21:
 #line 383 "CQL.y"  #line 478 "CQL.y"
 { {
                   globalParserState->currentRule = "array_index->expr";                   globalParserState->currentRule = "array_index->expr";
                   sprintf(msg,"BISON::array_index->expr\n");                   sprintf(msg,"BISON::array_index->expr\n");
                   printf_(msg);                   printf_(msg);
  
                   /*CQLValue tmp = _factory.getValue((CQLPredicate*)$1);*/  
                   /*$$ = new String(tmp.toString());*/  
                   CQLValue* _val = (CQLValue*)_factory.getObject(yyvsp[0]._predicate,Predicate,Value);                   CQLValue* _val = (CQLValue*)_factory.getObject(yyvsp[0]._predicate,Predicate,Value);
                   yyval._string = new String(_val->toString());                   yyval._string = new String(_val->toString());
                     _ObjPtr._ptr = yyval._string;
           _ObjPtr.type = Str;
           _ptrs.append(_ObjPtr);
               }               }
 break; break;
 case 22: case 22:
 #line 397 "CQL.y"  #line 493 "CQL.y"
 { {
                        globalParserState->currentRule = "array_index_list->array_index";                        globalParserState->currentRule = "array_index_list->array_index";
                        sprintf(msg,"BISON::array_index_list->array_index\n");                        sprintf(msg,"BISON::array_index_list->array_index\n");
Line 889 
Line 985 
                    }                    }
 break; break;
 case 23: case 23:
 #line 407 "CQL.y"  #line 503 "CQL.y"
 { {
             globalParserState->currentRule = "chain->literal";             globalParserState->currentRule = "chain->literal";
             sprintf(msg,"BISON::chain->literal\n");             sprintf(msg,"BISON::chain->literal\n");
Line 897 
Line 993 
  
             chain_state = CQLVALUE;             chain_state = CQLVALUE;
             yyval._node = _factory.makeObject(yyvsp[0]._value,Predicate);             yyval._node = _factory.makeObject(yyvsp[0]._value,Predicate);
             delete yyvsp[0]._value;  
         }         }
 break; break;
 case 24: case 24:
 #line 417 "CQL.y"  #line 512 "CQL.y"
 { {
             globalParserState->currentRule = "chain-> ( expr )";             globalParserState->currentRule = "chain-> ( expr )";
             sprintf(msg,"BISON::chain-> ( expr )\n");             sprintf(msg,"BISON::chain-> ( expr )\n");
Line 912 
Line 1007 
         }         }
 break; break;
 case 25: case 25:
 #line 426 "CQL.y"  #line 521 "CQL.y"
 { {
            globalParserState->currentRule = "chain->identifier";            globalParserState->currentRule = "chain->identifier";
            sprintf(msg,"BISON::chain->identifier\n");            sprintf(msg,"BISON::chain->identifier\n");
Line 920 
Line 1015 
  
            chain_state = CQLIDENTIFIER;            chain_state = CQLIDENTIFIER;
            yyval._node = _factory.makeObject(yyvsp[0]._identifier,Predicate);            yyval._node = _factory.makeObject(yyvsp[0]._identifier,Predicate);
            delete yyvsp[0]._identifier;  
         }         }
 break; break;
 case 26: case 26:
 #line 436 "CQL.y"  #line 530 "CQL.y"
 { {
             globalParserState->currentRule = "chain->identifier#literal_string";             globalParserState->currentRule = "chain->identifier#literal_string";
             sprintf(msg,"BISON::chain->identifier#literal_string\n");             sprintf(msg,"BISON::chain->identifier#literal_string\n");
Line 935 
Line 1029 
             CQLIdentifier _id(tmp);             CQLIdentifier _id(tmp);
             yyval._node = _factory.makeObject(&_id,Predicate);             yyval._node = _factory.makeObject(&_id,Predicate);
             chain_state = CQLIDENTIFIER;             chain_state = CQLIDENTIFIER;
             delete yyvsp[-2]._identifier; delete yyvsp[0]._string;  
         }         }
 break; break;
 case 27: case 27:
 #line 449 "CQL.y"  #line 542 "CQL.y"
 { {
             globalParserState->currentRule = "chain->scoped_property";             globalParserState->currentRule = "chain->scoped_property";
             sprintf(msg,"BISON::chain-> scoped_property\n");             sprintf(msg,"BISON::chain-> scoped_property\n");
Line 947 
Line 1040 
  
             chain_state = CQLIDENTIFIER;             chain_state = CQLIDENTIFIER;
             yyval._node = _factory.makeObject(yyvsp[0]._identifier,Predicate);             yyval._node = _factory.makeObject(yyvsp[0]._identifier,Predicate);
             delete yyvsp[0]._identifier;  
         }         }
 break; break;
 case 28: case 28:
 #line 459 "CQL.y"  #line 551 "CQL.y"
 { {
             globalParserState->currentRule = "chain->identifier( arg_list )";             globalParserState->currentRule = "chain->identifier( arg_list )";
             sprintf(msg,"BISON::chain-> identifier( arg_list )\n");             sprintf(msg,"BISON::chain-> identifier( arg_list )\n");
Line 960 
Line 1052 
             CQLFunction _func(*yyvsp[-3]._identifier,_arglist);             CQLFunction _func(*yyvsp[-3]._identifier,_arglist);
             yyval._node = (CQLPredicate*)(_factory.makeObject(&_func,Predicate));             yyval._node = (CQLPredicate*)(_factory.makeObject(&_func,Predicate));
             _arglist.clear();             _arglist.clear();
             delete yyvsp[-3]._identifier;  
         }         }
 break; break;
 case 29: case 29:
 #line 470 "CQL.y"  #line 561 "CQL.y"
 { {
             globalParserState->currentRule = "chain->chain.scoped_property";             globalParserState->currentRule = "chain->chain.scoped_property";
             sprintf(msg,"BISON::chain-> chain DOT scoped_property : chain_state = %d\n",chain_state);             sprintf(msg,"BISON::chain-> chain DOT scoped_property : chain_state = %d\n",chain_state);
Line 976 
Line 1067 
                 CQLChainedIdentifier _cid(*_id);                 CQLChainedIdentifier _cid(*_id);
                 _cid.append(*yyvsp[0]._identifier);                 _cid.append(*yyvsp[0]._identifier);
                 yyval._node = _factory.makeObject(&_cid,Predicate);                 yyval._node = _factory.makeObject(&_cid,Predicate);
                 delete yyvsp[0]._identifier;  
             }else if(chain_state == CQLCHAINEDIDENTIFIER){             }else if(chain_state == CQLCHAINEDIDENTIFIER){
                 CQLChainedIdentifier *_cid;                 CQLChainedIdentifier *_cid;
                 _cid = ((CQLChainedIdentifier*)(_factory.getObject(yyvsp[-2]._node,Predicate,ChainedIdentifier)));                 _cid = ((CQLChainedIdentifier*)(_factory.getObject(yyvsp[-2]._node,Predicate,ChainedIdentifier)));
                 _cid->append(*yyvsp[0]._identifier);                 _cid->append(*yyvsp[0]._identifier);
                 _factory.setObject(((CQLPredicate*)yyvsp[-2]._node),_cid,ChainedIdentifier);                 _factory.setObject(((CQLPredicate*)yyvsp[-2]._node),_cid,ChainedIdentifier);
                 yyval._node = yyvsp[-2]._node;                 yyval._node = yyvsp[-2]._node;
                 delete yyvsp[0]._identifier;  
             }else{             }else{
                 /* error */                 /* error */
                 String _msg("chain-> chain DOT scoped_property : chain state not CQLIDENTIFIER or CQLCHAINEDIDENTIFIER");                 String _msg("chain-> chain DOT scoped_property : chain state not CQLIDENTIFIER or CQLCHAINEDIDENTIFIER");
                   cleanup();
                 throw CQLSyntaxErrorException(                 throw CQLSyntaxErrorException(
                                         MessageLoaderParms(String("CQL.CQL_y.NOT_CHAINID_OR_IDENTIFIER"),                                         MessageLoaderParms(String("CQL.CQL_y.NOT_CHAINID_OR_IDENTIFIER"),
                                                            String("Chain state not a CQLIdentifier or a CQLChainedIdentifier while parsing rule $0 in position $1."),                                                            String("Chain state not a CQLIdentifier or a CQLChainedIdentifier while parsing rule $0 in position $1."),
Line 999 
Line 1089 
         }         }
 break; break;
 case 30: case 30:
 #line 503 "CQL.y"  #line 593 "CQL.y"
 { {
             globalParserState->currentRule = "chain->chain.identifier";             globalParserState->currentRule = "chain->chain.identifier";
             sprintf(msg,"BISON::chain->chain.identifier : chain_state = %d\n",chain_state);             sprintf(msg,"BISON::chain->chain.identifier : chain_state = %d\n",chain_state);
Line 1010 
Line 1100 
                 CQLChainedIdentifier _cid(*_id);                 CQLChainedIdentifier _cid(*_id);
                 _cid.append(*yyvsp[0]._identifier);                 _cid.append(*yyvsp[0]._identifier);
                 yyval._node = _factory.makeObject(&_cid,Predicate);                 yyval._node = _factory.makeObject(&_cid,Predicate);
                 delete yyvsp[0]._identifier;  
             }else if(chain_state == CQLCHAINEDIDENTIFIER){             }else if(chain_state == CQLCHAINEDIDENTIFIER){
                 CQLChainedIdentifier *_cid = ((CQLChainedIdentifier*)(_factory.getObject(yyvsp[-2]._node,Predicate,ChainedIdentifier)));                 CQLChainedIdentifier *_cid = ((CQLChainedIdentifier*)(_factory.getObject(yyvsp[-2]._node,Predicate,ChainedIdentifier)));
                 _cid->append(*yyvsp[0]._identifier);                 _cid->append(*yyvsp[0]._identifier);
                 _factory.setObject(((CQLPredicate*)yyvsp[-2]._node),_cid,ChainedIdentifier);                 _factory.setObject(((CQLPredicate*)yyvsp[-2]._node),_cid,ChainedIdentifier);
                 yyval._node = yyvsp[-2]._node;                 yyval._node = yyvsp[-2]._node;
                 delete yyvsp[0]._identifier;  
             }else{             }else{
                 /* error */                 /* error */
                 String _msg("chain-> chain DOT identifier : chain state not CQLIDENTIFIER or CQLCHAINEDIDENTIFIER");                 String _msg("chain-> chain DOT identifier : chain state not CQLIDENTIFIER or CQLCHAINEDIDENTIFIER");
                   cleanup();
                 throw CQLSyntaxErrorException(                 throw CQLSyntaxErrorException(
                                         MessageLoaderParms(String("CQL.CQL_y.NOT_CHAINID_OR_IDENTIFIER"),                                         MessageLoaderParms(String("CQL.CQL_y.NOT_CHAINID_OR_IDENTIFIER"),
                                                            String("Chain state not a CQLIdentifier or a CQLChainedIdentifier while parsing rule $0 in position $1."),                                                            String("Chain state not a CQLIdentifier or a CQLChainedIdentifier while parsing rule $0 in position $1."),
Line 1032 
Line 1121 
         }         }
 break; break;
 case 31: case 31:
 #line 534 "CQL.y"  #line 623 "CQL.y"
 { {
             globalParserState->currentRule = "chain->chain.identifier#literal_string";             globalParserState->currentRule = "chain->chain.identifier#literal_string";
             sprintf(msg,"BISON::chain->chain.identifier#literal_string : chain_state = %d\n",chain_state);             sprintf(msg,"BISON::chain->chain.identifier#literal_string : chain_state = %d\n",chain_state);
Line 1047 
Line 1136 
                 _cid.append(_id1);                 _cid.append(_id1);
                 _factory.setObject(((CQLPredicate*)yyvsp[-4]._node),&_cid,ChainedIdentifier);                 _factory.setObject(((CQLPredicate*)yyvsp[-4]._node),&_cid,ChainedIdentifier);
                 yyval._node = yyvsp[-4]._node;                 yyval._node = yyvsp[-4]._node;
                 delete yyvsp[-2]._identifier; delete yyvsp[0]._string;  
             }else if(chain_state == CQLCHAINEDIDENTIFIER){             }else if(chain_state == CQLCHAINEDIDENTIFIER){
               CQLChainedIdentifier *_cid =  ((CQLChainedIdentifier*)(_factory.getObject(yyvsp[-4]._node,Predicate,ChainedIdentifier)));               CQLChainedIdentifier *_cid =  ((CQLChainedIdentifier*)(_factory.getObject(yyvsp[-4]._node,Predicate,ChainedIdentifier)));
               String tmp(yyvsp[-2]._identifier->getName().getString());               String tmp(yyvsp[-2]._identifier->getName().getString());
Line 1056 
Line 1144 
                 _cid->append(_id1);                 _cid->append(_id1);
                 _factory.setObject(((CQLPredicate*)yyvsp[-4]._node),_cid,ChainedIdentifier);                 _factory.setObject(((CQLPredicate*)yyvsp[-4]._node),_cid,ChainedIdentifier);
                 yyval._node = yyvsp[-4]._node;                 yyval._node = yyvsp[-4]._node;
                 delete yyvsp[-2]._identifier; delete yyvsp[0]._string;  
             }else{             }else{
                 /* error */                 /* error */
                 String _msg("chain->chain.identifier#literal_string : chain state not CQLIDENTIFIER or CQLCHAINEDIDENTIFIER");                 String _msg("chain->chain.identifier#literal_string : chain state not CQLIDENTIFIER or CQLCHAINEDIDENTIFIER");
                   cleanup();
                 throw CQLSyntaxErrorException(                 throw CQLSyntaxErrorException(
                                         MessageLoaderParms(String("CQL.CQL_y.NOT_CHAINID_OR_IDENTIFIER"),                                         MessageLoaderParms(String("CQL.CQL_y.NOT_CHAINID_OR_IDENTIFIER"),
                                                            String("Chain state not a CQLIdentifier or a CQLChainedIdentifier while parsing rule $0 in position $1."),                                                            String("Chain state not a CQLIdentifier or a CQLChainedIdentifier while parsing rule $0 in position $1."),
Line 1073 
Line 1161 
         }         }
 break; break;
 case 32: case 32:
 #line 573 "CQL.y"  #line 661 "CQL.y"
 { {
             globalParserState->currentRule = "chain->chain[ array_index_list ]";             globalParserState->currentRule = "chain->chain[ array_index_list ]";
             sprintf(msg,"BISON::chain->chain[ array_index_list ] : chain_state = %d\n",chain_state);             sprintf(msg,"BISON::chain->chain[ array_index_list ] : chain_state = %d\n",chain_state);
Line 1087 
Line 1175 
                 CQLChainedIdentifier _cid(_id1);                 CQLChainedIdentifier _cid(_id1);
                 _factory.setObject(((CQLPredicate*)yyvsp[-3]._node),&_cid,ChainedIdentifier);                 _factory.setObject(((CQLPredicate*)yyvsp[-3]._node),&_cid,ChainedIdentifier);
                 yyval._node = yyvsp[-3]._node;                 yyval._node = yyvsp[-3]._node;
                 delete yyvsp[-1]._string;  
             }else if(chain_state == CQLCHAINEDIDENTIFIER || chain_state == CQLVALUE){             }else if(chain_state == CQLCHAINEDIDENTIFIER || chain_state == CQLVALUE){
                 CQLPredicate* _pred = (CQLPredicate*)yyvsp[-3]._node;                 CQLPredicate* _pred = (CQLPredicate*)yyvsp[-3]._node;
                 CQLChainedIdentifier *_cid = ((CQLChainedIdentifier*)(_factory.getObject(yyvsp[-3]._node,Predicate,ChainedIdentifier)));                 CQLChainedIdentifier *_cid = ((CQLChainedIdentifier*)(_factory.getObject(yyvsp[-3]._node,Predicate,ChainedIdentifier)));
Line 1103 
Line 1190 
                 }                 }
                 _factory.setObject(((CQLPredicate*)yyvsp[-3]._node),_cid,ChainedIdentifier);                 _factory.setObject(((CQLPredicate*)yyvsp[-3]._node),_cid,ChainedIdentifier);
                 yyval._node = yyvsp[-3]._node;                 yyval._node = yyvsp[-3]._node;
                 delete yyvsp[-1]._string;  
             }else{             }else{
                 /* error */                 /* error */
                 String _msg("chain->chain[ array_index_list ] : chain state not CQLIDENTIFIER or CQLCHAINEDIDENTIFIER or CQLVALUE");                 String _msg("chain->chain[ array_index_list ] : chain state not CQLIDENTIFIER or CQLCHAINEDIDENTIFIER or CQLVALUE");
                   cleanup();
                 throw CQLSyntaxErrorException(                 throw CQLSyntaxErrorException(
                                         MessageLoaderParms(String("CQL.CQL_y.NOT_CHAINID_OR_IDENTIFIER_OR_VALUE"),                                         MessageLoaderParms(String("CQL.CQL_y.NOT_CHAINID_OR_IDENTIFIER_OR_VALUE"),
                                                            String("Chain state not a CQLIdentifier or a CQLChainedIdentifier or a CQLValue while parsing rule $0 in position $1."),                                                            String("Chain state not a CQLIdentifier or a CQLChainedIdentifier or a CQLValue while parsing rule $0 in position $1."),
Line 1117 
Line 1204 
         }         }
 break; break;
 case 33: case 33:
 #line 617 "CQL.y"  #line 704 "CQL.y"
 { {
              globalParserState->currentRule = "concat->chain";              globalParserState->currentRule = "concat->chain";
              sprintf(msg,"BISON::concat->chain\n");              sprintf(msg,"BISON::concat->chain\n");
Line 1127 
Line 1214 
          }          }
 break; break;
 case 34: case 34:
 #line 625 "CQL.y"  #line 712 "CQL.y"
 { {
              globalParserState->currentRule = "concat->concat || chain";              globalParserState->currentRule = "concat->concat || chain";
              sprintf(msg,"BISON::concat||chain\n");              sprintf(msg,"BISON::concat||chain\n");
Line 1139 
Line 1226 
                 CQLTerm _term1(*_fctr1);                 CQLTerm _term1(*_fctr1);
                 _term1.appendOperation(concat,*_fctr2);                 _term1.appendOperation(concat,*_fctr2);
                 yyval._predicate = (CQLPredicate*)(_factory.makeObject(&_term1,Predicate));                 yyval._predicate = (CQLPredicate*)(_factory.makeObject(&_term1,Predicate));
                 delete yyvsp[-2]._predicate;  
                 CQLPredicate* _pred = (CQLPredicate*)yyvsp[0]._node;                 CQLPredicate* _pred = (CQLPredicate*)yyvsp[0]._node;
                 delete _pred;  
              }              }
          }          }
 break; break;
 case 35: case 35:
 #line 644 "CQL.y"  #line 729 "CQL.y"
 { {
              globalParserState->currentRule = "factor->concat";              globalParserState->currentRule = "factor->concat";
              sprintf(msg,"BISON::factor->concat\n");              sprintf(msg,"BISON::factor->concat\n");
Line 1156 
Line 1241 
          }          }
 break; break;
 case 36: case 36:
 #line 671 "CQL.y"  #line 756 "CQL.y"
 { {
            globalParserState->currentRule = "term->factor";            globalParserState->currentRule = "term->factor";
            sprintf(msg,"BISON::term->factor\n");            sprintf(msg,"BISON::term->factor\n");
Line 1166 
Line 1251 
        }        }
 break; break;
 case 37: case 37:
 #line 697 "CQL.y"  #line 782 "CQL.y"
 { {
             globalParserState->currentRule = "arith->term";             globalParserState->currentRule = "arith->term";
             sprintf(msg,"BISON::arith->term\n");             sprintf(msg,"BISON::arith->term\n");
Line 1178 
Line 1263 
         }         }
 break; break;
 case 38: case 38:
 #line 725 "CQL.y"  #line 810 "CQL.y"
 { {
                    globalParserState->currentRule = "value_symbol->#literal_string";                    globalParserState->currentRule = "value_symbol->#literal_string";
                    sprintf(msg,"BISON::value_symbol->#literal_string\n");                    sprintf(msg,"BISON::value_symbol->#literal_string\n");
Line 1188 
Line 1273 
                    tmp.append(*yyvsp[0]._string);                    tmp.append(*yyvsp[0]._string);
                    CQLIdentifier tmpid(tmp);                    CQLIdentifier tmpid(tmp);
                    yyval._value = new CQLValue(tmpid);                    yyval._value = new CQLValue(tmpid);
                    delete yyvsp[0]._string;                          _ObjPtr._ptr = yyval._value;
            _ObjPtr.type = Val;
            _ptrs.append(_ObjPtr);
                }                }
 break; break;
 case 39: case 39:
 #line 739 "CQL.y"  #line 826 "CQL.y"
 { {
                             globalParserState->currentRule = "arith_or_value_symbol->arith";                             globalParserState->currentRule = "arith_or_value_symbol->arith";
                             sprintf(msg,"BISON::arith_or_value_symbol->arith\n");                             sprintf(msg,"BISON::arith_or_value_symbol->arith\n");
Line 1202 
Line 1289 
                         }                         }
 break; break;
 case 40: case 40:
 #line 747 "CQL.y"  #line 834 "CQL.y"
 { {
                             /* make into predicate */                             /* make into predicate */
                             globalParserState->currentRule = "arith_or_value_symbol->value_symbol";                             globalParserState->currentRule = "arith_or_value_symbol->value_symbol";
Line 1211 
Line 1298 
  
                             CQLFactor _fctr(*yyvsp[0]._value);                             CQLFactor _fctr(*yyvsp[0]._value);
                             yyval._predicate = (CQLPredicate*)(_factory.makeObject(&_fctr, Predicate));                             yyval._predicate = (CQLPredicate*)(_factory.makeObject(&_fctr, Predicate));
                             delete yyvsp[0]._value;  
                         }                         }
 break; break;
 case 41: case 41:
 #line 760 "CQL.y"  #line 846 "CQL.y"
 { {
               globalParserState->currentRule = "comp_op->_EQ";               globalParserState->currentRule = "comp_op->_EQ";
               sprintf(msg,"BISON::comp_op->_EQ\n");               sprintf(msg,"BISON::comp_op->_EQ\n");
Line 1224 
Line 1310 
           }           }
 break; break;
 case 42: case 42:
 #line 767 "CQL.y"  #line 853 "CQL.y"
 { {
               globalParserState->currentRule = "comp_op->_NE";               globalParserState->currentRule = "comp_op->_NE";
               sprintf(msg,"BISON::comp_op->_NE\n");               sprintf(msg,"BISON::comp_op->_NE\n");
Line 1233 
Line 1319 
           }           }
 break; break;
 case 43: case 43:
 #line 774 "CQL.y"  #line 860 "CQL.y"
 { {
               globalParserState->currentRule = "comp_op->_GT";               globalParserState->currentRule = "comp_op->_GT";
               sprintf(msg,"BISON::comp_op->_GT\n");               sprintf(msg,"BISON::comp_op->_GT\n");
Line 1242 
Line 1328 
           }           }
 break; break;
 case 44: case 44:
 #line 781 "CQL.y"  #line 867 "CQL.y"
 { {
               globalParserState->currentRule = "comp_op->_LT";               globalParserState->currentRule = "comp_op->_LT";
               sprintf(msg,"BISON::comp_op->_LT\n");               sprintf(msg,"BISON::comp_op->_LT\n");
Line 1251 
Line 1337 
           }           }
 break; break;
 case 45: case 45:
 #line 788 "CQL.y"  #line 874 "CQL.y"
 { {
               globalParserState->currentRule = "comp_op->_GE";               globalParserState->currentRule = "comp_op->_GE";
               sprintf(msg,"BISON::comp_op->_GE\n");               sprintf(msg,"BISON::comp_op->_GE\n");
Line 1260 
Line 1346 
           }           }
 break; break;
 case 46: case 46:
 #line 795 "CQL.y"  #line 881 "CQL.y"
 { {
               globalParserState->currentRule = "comp_op->_LE";               globalParserState->currentRule = "comp_op->_LE";
               sprintf(msg,"BISON::comp_op->_LE\n");               sprintf(msg,"BISON::comp_op->_LE\n");
Line 1269 
Line 1355 
           }           }
 break; break;
 case 47: case 47:
 #line 804 "CQL.y"  #line 890 "CQL.y"
 { {
            globalParserState->currentRule = "comp->arith";            globalParserState->currentRule = "comp->arith";
            sprintf(msg,"BISON::comp->arith\n");            sprintf(msg,"BISON::comp->arith\n");
Line 1279 
Line 1365 
        }        }
 break; break;
 case 48: case 48:
 #line 812 "CQL.y"  #line 898 "CQL.y"
 { {
            globalParserState->currentRule = "comp->arith IS NOT _NULL";            globalParserState->currentRule = "comp->arith IS NOT _NULL";
            sprintf(msg,"BISON::comp->arith IS NOT _NULL\n");            sprintf(msg,"BISON::comp->arith IS NOT _NULL\n");
Line 1292 
Line 1378 
        }        }
 break; break;
 case 49: case 49:
 #line 823 "CQL.y"  #line 909 "CQL.y"
 { {
            globalParserState->currentRule = "comp->arith IS _NULL";            globalParserState->currentRule = "comp->arith IS _NULL";
            sprintf(msg,"BISON::comp->arith IS _NULL\n");            sprintf(msg,"BISON::comp->arith IS _NULL\n");
Line 1305 
Line 1391 
        }        }
 break; break;
 case 50: case 50:
 #line 834 "CQL.y"  #line 920 "CQL.y"
 { {
            globalParserState->currentRule = "comp->arith comp_op arith_or_value_symbol";            globalParserState->currentRule = "comp->arith comp_op arith_or_value_symbol";
            sprintf(msg,"BISON::comp->arith comp_op arith_or_value_symbol\n");            sprintf(msg,"BISON::comp->arith comp_op arith_or_value_symbol\n");
Line 1315 
Line 1401 
                 CQLExpression* _exp2 = (CQLExpression*)(_factory.getObject(yyvsp[0]._predicate,Predicate,Expression));                 CQLExpression* _exp2 = (CQLExpression*)(_factory.getObject(yyvsp[0]._predicate,Predicate,Expression));
                 CQLSimplePredicate _sp(*_exp1, *_exp2, yyvsp[-1]._opType);                 CQLSimplePredicate _sp(*_exp1, *_exp2, yyvsp[-1]._opType);
                 yyval._predicate = new CQLPredicate(_sp);                 yyval._predicate = new CQLPredicate(_sp);
                                   _ObjPtr._ptr = yyval._predicate;
               _ObjPtr.type = Pred;
               _ptrs.append(_ObjPtr);
            }else{            }else{
                 /* error */                 /* error */
                 String _msg("comp->arith comp_op arith_or_value_symbol : $1 is not simple OR $3 is not simple");                 String _msg("comp->arith comp_op arith_or_value_symbol : $1 is not simple OR $3 is not simple");
                   cleanup();
                 throw CQLSyntaxErrorException(                 throw CQLSyntaxErrorException(
                                         MessageLoaderParms(String("CQL.CQL_y.NOT_SIMPLE"),                                         MessageLoaderParms(String("CQL.CQL_y.NOT_SIMPLE"),
                                                            String("The CQLSimplePredicate is not simple while parsing rule $0 in position $1."),                                                            String("The CQLSimplePredicate is not simple while parsing rule $0 in position $1."),
Line 1328 
Line 1418 
        }        }
 break; break;
 case 51: case 51:
 #line 855 "CQL.y"  #line 945 "CQL.y"
 { {
            globalParserState->currentRule = "comp->value_symbol comp_op arith";            globalParserState->currentRule = "comp->value_symbol comp_op arith";
            sprintf(msg,"BISON::comp->value_symbol comp_op arith\n");            sprintf(msg,"BISON::comp->value_symbol comp_op arith\n");
Line 1339 
Line 1429 
                 CQLExpression* _exp2 = (CQLExpression*)(_factory.getObject(yyvsp[0]._predicate,Predicate,Expression));                 CQLExpression* _exp2 = (CQLExpression*)(_factory.getObject(yyvsp[0]._predicate,Predicate,Expression));
                 CQLSimplePredicate _sp(*_exp1, *_exp2, yyvsp[-1]._opType);                 CQLSimplePredicate _sp(*_exp1, *_exp2, yyvsp[-1]._opType);
                 yyval._predicate = new CQLPredicate(_sp);                 yyval._predicate = new CQLPredicate(_sp);
                                   _ObjPtr._ptr = yyval._predicate;
               _ObjPtr.type = Pred;
               _ptrs.append(_ObjPtr);
            }else{            }else{
                 /* error */                 /* error */
                 String _msg("comp->value_symbol comp_op arith : $3 is not simple");                 String _msg("comp->value_symbol comp_op arith : $3 is not simple");
                   cleanup();
                 throw CQLSyntaxErrorException(                 throw CQLSyntaxErrorException(
                                         MessageLoaderParms(String("CQL.CQL_y.NOT_SIMPLE"),                                         MessageLoaderParms(String("CQL.CQL_y.NOT_SIMPLE"),
                                                            String("The CQLSimplePredicate is not simple while parsing rule $0 in position $1."),                                                            String("The CQLSimplePredicate is not simple while parsing rule $0 in position $1."),
Line 1353 
Line 1447 
        }        }
 break; break;
 case 52: case 52:
 #line 878 "CQL.y"  #line 972 "CQL.y"
 { {
                 globalParserState->currentRule = "comp->value_symbol comp_op value_symbol";                 globalParserState->currentRule = "comp->value_symbol comp_op value_symbol";
                 sprintf(msg,"BISON::comp->value_symbol comp_op value_symbol\n");                 sprintf(msg,"BISON::comp->value_symbol comp_op value_symbol\n");
Line 1363 
Line 1457 
                 CQLExpression* _exp2 = (CQLExpression*)(_factory.makeObject(yyvsp[0]._value,Expression));                 CQLExpression* _exp2 = (CQLExpression*)(_factory.makeObject(yyvsp[0]._value,Expression));
                 CQLSimplePredicate _sp(*_exp1, *_exp2, yyvsp[-1]._opType);                 CQLSimplePredicate _sp(*_exp1, *_exp2, yyvsp[-1]._opType);
                 yyval._predicate = new CQLPredicate(_sp);                 yyval._predicate = new CQLPredicate(_sp);
                                            _ObjPtr._ptr = yyval._predicate;
                   _ObjPtr.type = Pred;
                   _ptrs.append(_ObjPtr);
        }        }
 break; break;
 case 53: case 53:
 #line 889 "CQL.y"  #line 986 "CQL.y"
 { {
            globalParserState->currentRule = "comp->arith _ISA identifier";            globalParserState->currentRule = "comp->arith _ISA identifier";
            /* make sure $1 isSimple(), get its expression, make simplepred->predicate */            /* make sure $1 isSimple(), get its expression, make simplepred->predicate */
Line 1379 
Line 1476 
            CQLSimplePredicate _sp(*_expr1, *_expr2, ISA);            CQLSimplePredicate _sp(*_expr1, *_expr2, ISA);
            _factory.setObject(yyvsp[-2]._predicate,&_sp,SimplePredicate);            _factory.setObject(yyvsp[-2]._predicate,&_sp,SimplePredicate);
            yyval._predicate = yyvsp[-2]._predicate;            yyval._predicate = yyvsp[-2]._predicate;
            delete yyvsp[0]._identifier;  
        }        }
 break; break;
 case 54: case 54:
 #line 904 "CQL.y"  #line 1000 "CQL.y"
 { {
            globalParserState->currentRule = "comp->arith _LIKE literal_string";            globalParserState->currentRule = "comp->arith _LIKE literal_string";
            sprintf(msg,"BISON::comp->arith _LIKE literal_string\n");            sprintf(msg,"BISON::comp->arith _LIKE literal_string\n");
Line 1395 
Line 1491 
            CQLSimplePredicate _sp(*_expr1, *_expr2, LIKE);            CQLSimplePredicate _sp(*_expr1, *_expr2, LIKE);
            _factory.setObject(yyvsp[-2]._predicate,&_sp,SimplePredicate);            _factory.setObject(yyvsp[-2]._predicate,&_sp,SimplePredicate);
            yyval._predicate = yyvsp[-2]._predicate;            yyval._predicate = yyvsp[-2]._predicate;
            delete yyvsp[0]._string;  
        }        }
 break; break;
 case 55: case 55:
 #line 919 "CQL.y"  #line 1014 "CQL.y"
 { {
                   globalParserState->currentRule = "expr_factor->comp";                   globalParserState->currentRule = "expr_factor->comp";
                   sprintf(msg,"BISON::expr_factor->comp\n");                   sprintf(msg,"BISON::expr_factor->comp\n");
Line 1409 
Line 1504 
               }               }
 break; break;
 case 56: case 56:
 #line 927 "CQL.y"  #line 1022 "CQL.y"
 { {
                   globalParserState->currentRule = "expr_factor->NOT comp";                   globalParserState->currentRule = "expr_factor->NOT comp";
                   sprintf(msg,"BISON::expr_factor->NOT comp\n");                   sprintf(msg,"BISON::expr_factor->NOT comp\n");
Line 1420 
Line 1515 
               }               }
 break; break;
 case 57: case 57:
 #line 938 "CQL.y"  #line 1033 "CQL.y"
 { {
                 globalParserState->currentRule = "expr_term->expr_factor";                 globalParserState->currentRule = "expr_term->expr_factor";
                 sprintf(msg,"BISON::expr_term->expr_factor\n");                 sprintf(msg,"BISON::expr_term->expr_factor\n");
Line 1430 
Line 1525 
             }             }
 break; break;
 case 58: case 58:
 #line 946 "CQL.y"  #line 1041 "CQL.y"
 { {
                 globalParserState->currentRule = "expr_term->expr_term AND expr_factor";                 globalParserState->currentRule = "expr_term->expr_term AND expr_factor";
                 sprintf(msg,"BISON::expr_term->expr_term AND expr_factor\n");                 sprintf(msg,"BISON::expr_term->expr_term AND expr_factor\n");
Line 1439 
Line 1534 
                 yyval._predicate = new CQLPredicate();                 yyval._predicate = new CQLPredicate();
                 yyval._predicate->appendPredicate(*yyvsp[-2]._predicate);                 yyval._predicate->appendPredicate(*yyvsp[-2]._predicate);
                 yyval._predicate->appendPredicate(*yyvsp[0]._predicate, AND);                 yyval._predicate->appendPredicate(*yyvsp[0]._predicate, AND);
                                   _ObjPtr._ptr = yyval._predicate;
               _ObjPtr.type = Pred;
               _ptrs.append(_ObjPtr);
             }             }
 break; break;
 case 59: case 59:
 #line 958 "CQL.y"  #line 1056 "CQL.y"
 { {
           globalParserState->currentRule = "expr->expr_term";           globalParserState->currentRule = "expr->expr_term";
           sprintf(msg,"BISON::expr->expr_term\n");           sprintf(msg,"BISON::expr->expr_term\n");
Line 1452 
Line 1550 
        }        }
 break; break;
 case 60: case 60:
 #line 966 "CQL.y"  #line 1064 "CQL.y"
 { {
            globalParserState->currentRule = "expr->expr OR expr_term";            globalParserState->currentRule = "expr->expr OR expr_term";
            sprintf(msg,"BISON::expr->expr OR expr_term\n");            sprintf(msg,"BISON::expr->expr OR expr_term\n");
Line 1460 
Line 1558 
            yyval._predicate = new CQLPredicate();            yyval._predicate = new CQLPredicate();
            yyval._predicate->appendPredicate(*yyvsp[-2]._predicate);            yyval._predicate->appendPredicate(*yyvsp[-2]._predicate);
            yyval._predicate->appendPredicate(*yyvsp[0]._predicate, OR);            yyval._predicate->appendPredicate(*yyvsp[0]._predicate, OR);
                   _ObjPtr._ptr = yyval._predicate;
         _ObjPtr.type = Pred;
         _ptrs.append(_ObjPtr);
        }        }
 break; break;
 case 61: case 61:
 #line 976 "CQL.y"  #line 1077 "CQL.y"
 {;} {;}
 break; break;
 case 62: case 62:
 #line 978 "CQL.y"  #line 1079 "CQL.y"
 { {
                globalParserState->currentRule = "arg_list->STAR";                globalParserState->currentRule = "arg_list->STAR";
                sprintf(msg,"BISON::arg_list->STAR\n");                sprintf(msg,"BISON::arg_list->STAR\n");
Line 1485 
Line 1586 
            }            }
 break; break;
 case 63: case 63:
 #line 994 "CQL.y"  #line 1095 "CQL.y"
 { {
                    globalParserState->currentRule = "arg_list->arg_list_sub->expr";                    globalParserState->currentRule = "arg_list->arg_list_sub->expr";
                    sprintf(msg,"BISON::arg_list_sub->expr\n");                    sprintf(msg,"BISON::arg_list_sub->expr\n");
Line 1501 
Line 1602 
            }            }
 break; break;
 case 64: case 64:
 #line 1055 "CQL.y"  #line 1156 "CQL.y"
 { {
                      globalParserState->currentRule = "from_specifier->class_path";                      globalParserState->currentRule = "from_specifier->class_path";
                      sprintf(msg,"BISON::from_specifier->class_path\n");                      sprintf(msg,"BISON::from_specifier->class_path\n");
                      printf_(msg);                      printf_(msg);
  
                      globalParserState->statement->appendClassPath(*yyvsp[0]._identifier);                      globalParserState->statement->appendClassPath(*yyvsp[0]._identifier);
                      delete yyvsp[0]._identifier;  
                  }                  }
 break; break;
 case 65: case 65:
 #line 1065 "CQL.y"  #line 1165 "CQL.y"
 { {
                         globalParserState->currentRule = "from_specifier->class_path AS identifier";                         globalParserState->currentRule = "from_specifier->class_path AS identifier";
                         sprintf(msg,"BISON::from_specifier->class_path AS identifier\n");                         sprintf(msg,"BISON::from_specifier->class_path AS identifier\n");
Line 1522 
Line 1622 
                         String _alias(yyvsp[0]._identifier->getName().getString());                         String _alias(yyvsp[0]._identifier->getName().getString());
                         globalParserState->statement->insertClassPathAlias(_class,_alias);                         globalParserState->statement->insertClassPathAlias(_class,_alias);
                         globalParserState->statement->appendClassPath(_class);                         globalParserState->statement->appendClassPath(_class);
                         delete yyvsp[-2]._identifier; delete yyvsp[0]._identifier;  
                   }                   }
 break; break;
 case 66: case 66:
 #line 1077 "CQL.y"  #line 1176 "CQL.y"
 { {
                         globalParserState->currentRule = "from_specifier->class_path identifier";                         globalParserState->currentRule = "from_specifier->class_path identifier";
                         sprintf(msg,"BISON::from_specifier->class_path identifier\n");                         sprintf(msg,"BISON::from_specifier->class_path identifier\n");
Line 1536 
Line 1635 
                         String _alias(yyvsp[0]._identifier->getName().getString());                         String _alias(yyvsp[0]._identifier->getName().getString());
                         globalParserState->statement->insertClassPathAlias(_class,_alias);                         globalParserState->statement->insertClassPathAlias(_class,_alias);
                         globalParserState->statement->appendClassPath(_class);                         globalParserState->statement->appendClassPath(_class);
                         delete yyvsp[-1]._identifier; delete yyvsp[0]._identifier;  
                   }                   }
 break; break;
 case 67: case 67:
 #line 1091 "CQL.y"  #line 1189 "CQL.y"
 { {
                     globalParserState->currentRule = "from_criteria->from_specifier";                     globalParserState->currentRule = "from_criteria->from_specifier";
                     sprintf(msg,"BISON::from_criteria->from_specifier\n");                     sprintf(msg,"BISON::from_criteria->from_specifier\n");
Line 1548 
Line 1646 
                 }                 }
 break; break;
 case 68: case 68:
 #line 1099 "CQL.y"  #line 1197 "CQL.y"
 { {
                 globalParserState->currentRule = "star_expr->STAR";                 globalParserState->currentRule = "star_expr->STAR";
                 sprintf(msg,"BISON::star_expr->STAR\n");                 sprintf(msg,"BISON::star_expr->STAR\n");
Line 1559 
Line 1657 
             }             }
 break; break;
 case 69: case 69:
 #line 1108 "CQL.y"  #line 1206 "CQL.y"
 { {
                 globalParserState->currentRule = "star_expr->chain.*";                 globalParserState->currentRule = "star_expr->chain.*";
                 sprintf(msg,"BISON::star_expr->chain.*\n");                 sprintf(msg,"BISON::star_expr->chain.*\n");
Line 1569 
Line 1667 
                 CQLIdentifier _id("*");                 CQLIdentifier _id("*");
                 _cid->append(_id);                 _cid->append(_id);
                 yyval._chainedIdentifier = _cid;                 yyval._chainedIdentifier = _cid;
                                            _ObjPtr._ptr = yyval._chainedIdentifier;
                   _ObjPtr.type = CId;
                   _ptrs.append(_ObjPtr);
             }             }
 break; break;
 case 70: case 70:
 #line 1121 "CQL.y"  #line 1222 "CQL.y"
 { {
                      globalParserState->currentRule = "selected_entry->expr";                      globalParserState->currentRule = "selected_entry->expr";
                      sprintf(msg,"BISON::selected_entry->expr\n");                      sprintf(msg,"BISON::selected_entry->expr\n");
Line 1583 
Line 1684 
                      }else{                      }else{
                         /* error */                         /* error */
                         String _msg("selected_entry->expr : $1 is not a simple value");                         String _msg("selected_entry->expr : $1 is not a simple value");
                           cleanup();
                         throw CQLSyntaxErrorException(                         throw CQLSyntaxErrorException(
                                         MessageLoaderParms(String("CQL.CQL_y.NOT_SIMPLE_VALUE"),                                         MessageLoaderParms(String("CQL.CQL_y.NOT_SIMPLE_VALUE"),
                                                            String("The CQLPredicate is not a simple value while parsing rule $0 in position $1."),                                                            String("The CQLPredicate is not a simple value while parsing rule $0 in position $1."),
Line 1593 
Line 1695 
                  }                  }
 break; break;
 case 71: case 71:
 #line 1140 "CQL.y"  #line 1242 "CQL.y"
 { {
                      globalParserState->currentRule = "selected_entry->star_expr";                      globalParserState->currentRule = "selected_entry->star_expr";
                      sprintf(msg,"BISON::selected_entry->star_expr\n");                      sprintf(msg,"BISON::selected_entry->star_expr\n");
Line 1602 
Line 1704 
                  }                  }
 break; break;
 case 72: case 72:
 #line 1149 "CQL.y"  #line 1251 "CQL.y"
 { {
                 globalParserState->currentRule = "select_list->selected_entry select_list_tail";                 globalParserState->currentRule = "select_list->selected_entry select_list_tail";
                 sprintf(msg,"BISON::select_list->selected_entry select_list_tail\n");                 sprintf(msg,"BISON::select_list->selected_entry select_list_tail\n");
Line 1610 
Line 1712 
             }             }
 break; break;
 case 73: case 73:
 #line 1156 "CQL.y"  #line 1258 "CQL.y"
 {;} {;}
 break; break;
 case 74: case 74:
 #line 1158 "CQL.y"  #line 1260 "CQL.y"
 { {
                        globalParserState->currentRule = "select_list_tail->COMMA selected_entry select_list_tail";                        globalParserState->currentRule = "select_list_tail->COMMA selected_entry select_list_tail";
                        sprintf(msg,"BISON::select_list_tail->COMMA selected_entry select_list_tail\n");                        sprintf(msg,"BISON::select_list_tail->COMMA selected_entry select_list_tail\n");
Line 1622 
Line 1724 
                    }                    }
 break; break;
 case 75: case 75:
 #line 1166 "CQL.y"  #line 1268 "CQL.y"
 { {
                         globalParserState->currentRule = "search_condition->expr";                         globalParserState->currentRule = "search_condition->expr";
                         sprintf(msg,"BISON::search_condition->expr\n");                         sprintf(msg,"BISON::search_condition->expr\n");
Line 1631 
Line 1733 
                    }                    }
 break; break;
 case 76: case 76:
 #line 1174 "CQL.y"  #line 1276 "CQL.y"
 {;}  {}
 break; break;
 case 77: case 77:
 #line 1176 "CQL.y"  #line 1278 "CQL.y"
 { {
                      globalParserState->currentRule = "optional_where->WHERE search_condition";                      globalParserState->currentRule = "optional_where->WHERE search_condition";
                      sprintf(msg,"BISON::optional_where->WHERE search_condition\n");                      sprintf(msg,"BISON::optional_where->WHERE search_condition\n");
Line 1644 
Line 1746 
                  }                  }
 break; break;
 case 78: case 78:
 #line 1185 "CQL.y"  #line 1287 "CQL.y"
 { {
                        globalParserState->currentRule = "select_statement";                        globalParserState->currentRule = "select_statement";
                        sprintf(msg,"select_statement\n\n");                        sprintf(msg,"select_statement\n\n");
                        printf_(msg);                        printf_(msg);
                                    cleanup();
                    }                    }
 break; break;
 #line 1655 "y.tab.c"  #line 1758 "y.tab.c"
     }     }
     yyssp -= yym;     yyssp -= yym;
     yystate = *yyssp;     yystate = *yyssp;


Legend:
Removed from v.1.7  
changed lines
  Added in v.1.8

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2