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

version 1.253, 2024/09/07 16:30:26 version 1.254, 2024/09/13 04:01:22
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 can not 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();

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


E-mail: