Diff for /parser3/src/classes/string.C between versions 1.19 and 1.20

version 1.19, 2001/03/29 17:32:57 version 1.20, 2001/03/29 17:34:26
Line 99  static void split_list(Request& r, const Line 99  static void split_list(Request& r, const
         if(delim.size()) {          if(delim.size()) {
                 size_t pos_after=0;                  size_t pos_after=0;
                 int pos_before;                  int pos_before;
                 while((pos_before=string.pos(delim, pos_after))>=0) { // we have 'delim' in 'string'?                  // while we have 'delim' in 'string'...
                   while((pos_before=string.pos(delim, pos_after))>=0) {
                         list+=&string.piece(pos_after, pos_before);                          list+=&string.piece(pos_after, pos_before);
                         pos_after=pos_before+delim.size();                          pos_after=pos_before+delim.size();
                 }                  }
Line 117  static void _lsplit(Request& r, const St Line 118  static void _lsplit(Request& r, const St
   
         Array list(pool);          Array list(pool);
         split_list(r, method_name, params, string, list);          split_list(r, method_name, params, string, list);
         Table& table=*new(pool) Table(pool, &string, 0);          Table& table=*new(pool) Table(pool, &string, 0/*nameless*/);
   
         int size=list.size();          int size=list.size();
         for(int i=0; i<size; i++) {          for(int i=0; i<size; i++) {
                 Array& row=*new(pool) Array(pool, 1);                  Array& row=*new(pool) Array(pool, 1/*row preallocate(and only)*/);
                 table+=&(row+=list.quick_get(i));                  table+=&(row+=list.quick_get(i));
         }          }
   
Line 134  static void _rsplit(Request& r, const St Line 135  static void _rsplit(Request& r, const St
   
         Array list(pool);          Array list(pool);
         split_list(r, method_name, params, string, list);          split_list(r, method_name, params, string, list);
         Table& table=*new(pool) Table(pool, &string, 0);          Table& table=*new(pool) Table(pool, &string, 0/*nameless*/);
   
         for(int i=list.size(); --i>=0; ) {          for(int i=list.size(); --i>=0; ) {
                 Array& row=*new(pool) Array(pool, 1);                  Array& row=*new(pool) Array(pool, 1/*row preallocate(and only)*/);
                 table+=&(row+=list.get(i));                  table+=&(row+=list.get(i));
         }          }
   

Removed from v.1.19  
changed lines
  Added in v.1.20


E-mail: