Diff for /parser3/src/classes/string.C between versions 1.253 and 1.255

version 1.253, 2024/09/07 16:30:26 version 1.255, 2024/09/28 14:37:53
Line 221  static void split_action(Table& , ArrayS Line 221  static void split_action(Table& , ArrayS
 }  }
   
 static void split_list(Value& delim_value, const String& string, ArrayString& result) {  static void split_list(Value& delim_value, const String& string, ArrayString& result) {
         if(Value* value=delim_value.as(VREGEX_TYPE)){          if(VRegex *vregex=dynamic_cast<VRegex*>(&delim_value)){
                 VRegex *vregex=static_cast<VRegex*>(value);  
                 vregex->study();                  vregex->study();
   
                 int matches_count=0;                  int matches_count=0;
Line 386  static void _match(Request& r, MethodPar Line 385  static void _match(Request& r, MethodPar
         Value& regexp=params.as_no_junction(0, "regexp must not be code");          Value& regexp=params.as_no_junction(0, "regexp must not be code");
         Value* options=(params_count>1)?&params.as_no_junction(1, OPTIONS_MUST_NOT_BE_CODE):0;          Value* options=(params_count>1)?&params.as_no_junction(1, OPTIONS_MUST_NOT_BE_CODE):0;
   
         VRegex* vregex;          VRegex* vregex=dynamic_cast<VRegex*>(&regexp);
         VRegexCleaner vrcleaner;          VRegexCleaner vrcleaner;
   
         if(Value* value=regexp.as(VREGEX_TYPE)){          if(vregex){
                 if(options && options->is_defined())                  if(options && options->is_defined())
                         throw Exception(PARSER_RUNTIME, 0, "you can not specify regex-object and options together");                          throw Exception(PARSER_RUNTIME, 0, "you cannot specify regex-object and options together");
                 vregex=static_cast<VRegex*>(value);  
         } else {          } else {
                 vregex=new VRegex(r.charsets.source(), &regexp.as_string(), (options) ? (&options->as_string()) : 0);                  vregex=new VRegex(r.charsets.source(), &regexp.as_string(), (options) ? (&options->as_string()) : 0);
                 vregex->study();                  vregex->study();
Line 488  public: Line 486  public:
         bool add_row(SQL_Error& /*error*/) { /* ignore */ return false; }          bool add_row(SQL_Error& /*error*/) { /* ignore */ return false; }
         bool add_row_cell(SQL_Error& error, const char* str, size_t) {          bool add_row_cell(SQL_Error& error, const char* str, size_t) {
                 if(got_cell) {                  if(got_cell) {
                         error=SQL_Error("result must not contain more then one row");                          error=SQL_Error("result must contain no more than one row");
                         return true;                          return true;
                 }                  }
                 try {                  try {

Removed from v.1.253  
changed lines
  Added in v.1.255


E-mail: