Ignore:
Timestamp:
Jul 29, 2006, 5:04:22 PM (19 years ago)
Author:
darin
Message:

JavaScriptCore:

  • Removed tabs from these source files that still had them. We don't use them; that way source files look fine in editors that have tabs set to 8 spaces or to 4 spaces.
  • Removed allow-tabs Subversion property from the files too.
  • bindings/NP_jsobject.cpp:
  • bindings/c/c_utility.cpp:
  • bindings/jni/jni_runtime.cpp:
  • bindings/jni/jni_utility.cpp:
  • bindings/objc/objc_utility.mm:
  • bindings/runtime.cpp:
  • bindings/runtime_method.cpp:
  • bindings/testbindings.cpp:
  • bindings/testbindings.mm:
  • kjs/date_object.cpp:
  • kjs/function.cpp:
  • kjs/list.cpp:
  • kjs/nodes.cpp:
  • kjs/nodes.h:
  • kjs/string_object.cpp:
  • kjs/ustring.cpp:

WebCore:

  • Removed tabs from these source files that still had them. We don't use them; that way source files look fine in editors that have tabs set to 8 spaces or to 4 spaces.
  • Removed allow-tabs Subversion property from the files too.
  • bindings/objc/WebScriptObject.h:
  • bindings/objc/WebScriptObject.mm:
  • platform/FontData.cpp:

WebKit:

  • Removed tabs from these source files that still had them. We don't use them; that way source files look fine in editors that have tabs set to 8 spaces or to 4 spaces.
  • Removed allow-tabs Subversion property from the files too.
  • DefaultDelegates/WebDefaultPolicyDelegate.m:
  • History/WebHistory.m:
  • Misc/WebDownload.m:
  • Misc/WebIconDatabase.m:
  • Misc/WebKitErrors.m:
  • Misc/WebKitLogging.m:
  • Misc/WebNSDataExtras.m:
  • Misc/WebNSFileManagerExtras.m:
  • Panels/WebPanelAuthenticationHandler.m:
  • Plugins/WebBaseNetscapePluginView.m:
  • Plugins/npfunctions.h:
  • WebCoreSupport/WebSubresourceLoader.m:
  • WebView/WebMainResourceLoader.m:
  • WebView/WebView.h:
  • WebView/WebView.m:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/kjs/string_object.cpp

    • Property allow-tabs deleted
    r15468 r15698  
    107107/* Source for string_object.lut.h
    108108@begin stringTable 26
    109   toString              StringProtoFunc::ToString       DontEnum|Function       0
    110   valueOf               StringProtoFunc::ValueOf        DontEnum|Function       0
    111   charAt                StringProtoFunc::CharAt DontEnum|Function       1
    112   charCodeAt            StringProtoFunc::CharCodeAt     DontEnum|Function       1
    113   concat                StringProtoFunc::Concat DontEnum|Function       1
    114   indexOf               StringProtoFunc::IndexOf        DontEnum|Function       1
    115   lastIndexOf           StringProtoFunc::LastIndexOf    DontEnum|Function       1
    116   match                 StringProtoFunc::Match  DontEnum|Function       1
    117   replace               StringProtoFunc::Replace        DontEnum|Function       2
    118   search                StringProtoFunc::Search DontEnum|Function       1
    119   slice                 StringProtoFunc::Slice  DontEnum|Function       2
    120   split                 StringProtoFunc::Split  DontEnum|Function       2
    121   substr                StringProtoFunc::Substr DontEnum|Function       2
    122   substring             StringProtoFunc::Substring      DontEnum|Function       2
    123   toLowerCase           StringProtoFunc::ToLowerCase    DontEnum|Function       0
    124   toUpperCase           StringProtoFunc::ToUpperCase    DontEnum|Function       0
    125   toLocaleLowerCase     StringProtoFunc::ToLocaleLowerCase DontEnum|Function    0
    126   toLocaleUpperCase     StringProtoFunc::ToLocaleUpperCase DontEnum|Function    0
     109  toString              StringProtoFunc::ToString       DontEnum|Function       0
     110  valueOf               StringProtoFunc::ValueOf        DontEnum|Function       0
     111  charAt                StringProtoFunc::CharAt         DontEnum|Function       1
     112  charCodeAt            StringProtoFunc::CharCodeAt     DontEnum|Function       1
     113  concat                StringProtoFunc::Concat         DontEnum|Function       1
     114  indexOf               StringProtoFunc::IndexOf        DontEnum|Function       1
     115  lastIndexOf           StringProtoFunc::LastIndexOf    DontEnum|Function       1
     116  match                 StringProtoFunc::Match          DontEnum|Function       1
     117  replace               StringProtoFunc::Replace        DontEnum|Function       2
     118  search                StringProtoFunc::Search         DontEnum|Function       1
     119  slice                 StringProtoFunc::Slice          DontEnum|Function       2
     120  split                 StringProtoFunc::Split          DontEnum|Function       2
     121  substr                StringProtoFunc::Substr         DontEnum|Function       2
     122  substring             StringProtoFunc::Substring      DontEnum|Function       2
     123  toLowerCase           StringProtoFunc::ToLowerCase    DontEnum|Function       0
     124  toUpperCase           StringProtoFunc::ToUpperCase    DontEnum|Function       0
     125  toLocaleLowerCase     StringProtoFunc::ToLocaleLowerCase DontEnum|Function    0
     126  toLocaleUpperCase     StringProtoFunc::ToLocaleUpperCase DontEnum|Function    0
    127127#
    128128# Under here: html extension, should only exist if KJS_PURE_ECMA is not defined
    129129# I guess we need to generate two hashtables in the .lut.h file, and use #ifdef
    130130# to select the right one... TODO. #####
    131   big                   StringProtoFunc::Big            DontEnum|Function       0
    132   small                 StringProtoFunc::Small  DontEnum|Function       0
    133   blink                 StringProtoFunc::Blink  DontEnum|Function       0
    134   bold                  StringProtoFunc::Bold   DontEnum|Function       0
    135   fixed                 StringProtoFunc::Fixed  DontEnum|Function       0
    136   italics               StringProtoFunc::Italics        DontEnum|Function       0
    137   strike                StringProtoFunc::Strike DontEnum|Function       0
    138   sub                   StringProtoFunc::Sub            DontEnum|Function       0
    139   sup                   StringProtoFunc::Sup            DontEnum|Function       0
    140   fontcolor             StringProtoFunc::Fontcolor      DontEnum|Function       1
    141   fontsize              StringProtoFunc::Fontsize       DontEnum|Function       1
    142   anchor                StringProtoFunc::Anchor DontEnum|Function       1
    143   link                  StringProtoFunc::Link   DontEnum|Function       1
     131  big                   StringProtoFunc::Big            DontEnum|Function       0
     132  small                 StringProtoFunc::Small          DontEnum|Function       0
     133  blink                 StringProtoFunc::Blink          DontEnum|Function       0
     134  bold                  StringProtoFunc::Bold           DontEnum|Function       0
     135  fixed                 StringProtoFunc::Fixed          DontEnum|Function       0
     136  italics               StringProtoFunc::Italics        DontEnum|Function       0
     137  strike                StringProtoFunc::Strike         DontEnum|Function       0
     138  sub                   StringProtoFunc::Sub            DontEnum|Function       0
     139  sup                   StringProtoFunc::Sup            DontEnum|Function       0
     140  fontcolor             StringProtoFunc::Fontcolor      DontEnum|Function       1
     141  fontsize              StringProtoFunc::Fontsize       DontEnum|Function       1
     142  anchor                StringProtoFunc::Anchor         DontEnum|Function       1
     143  link                  StringProtoFunc::Link           DontEnum|Function       1
    144144@end
    145145*/
     
    488488      // Exec
    489489      if ((reg->flags() & RegExp::Global) == 0) {
    490         // case without 'g' flag is handled like RegExp.prototype.exec
    491         if (mstr.isNull()) {
    492           result = jsNull();
    493         } else {
    494           result = regExpObj->arrayOfMatches(exec,mstr);
    495         }
     490        // case without 'g' flag is handled like RegExp.prototype.exec
     491        if (mstr.isNull()) {
     492          result = jsNull();
     493        } else {
     494          result = regExpObj->arrayOfMatches(exec,mstr);
     495        }
    496496      } else {
    497         // return array of matches
    498         List list;
    499         int lastIndex = 0;
    500         while (pos >= 0) {
     497        // return array of matches
     498        List list;
     499        int lastIndex = 0;
     500        while (pos >= 0) {
    501501          if (mstr.isNull())
    502502            list.append(jsUndefined());
    503503          else
    504             list.append(jsString(mstr));
    505           lastIndex = pos;
    506           pos += mstr.isEmpty() ? 1 : mstr.size();
    507           mstr = regExpObj->performMatch(reg, u, pos, &pos);
    508         }
    509         if (imp)
    510           imp->put(exec, "lastIndex", jsNumber(lastIndex), DontDelete|DontEnum);
    511         if (list.isEmpty()) {
    512           // if there are no matches at all, it's important to return
    513           // Null instead of an empty array, because this matches
    514           // other browsers and because Null is a false value.
    515           result = jsNull();
    516         } else {
    517           result = exec->lexicalInterpreter()->builtinArray()->construct(exec, list);
    518         }
     504            list.append(jsString(mstr));
     505          lastIndex = pos;
     506          pos += mstr.isEmpty() ? 1 : mstr.size();
     507          mstr = regExpObj->performMatch(reg, u, pos, &pos);
     508        }
     509        if (imp)
     510          imp->put(exec, "lastIndex", jsNumber(lastIndex), DontDelete|DontEnum);
     511        if (list.isEmpty()) {
     512          // if there are no matches at all, it's important to return
     513          // Null instead of an empty array, because this matches
     514          // other browsers and because Null is a false value.
     515          result = jsNull();
     516        } else {
     517          result = exec->lexicalInterpreter()->builtinArray()->construct(exec, list);
     518        }
    519519      }
    520520    }
     
    553553      RegExp *reg = static_cast<RegExpImp *>(a0)->regExp();
    554554      if (u.isEmpty() && !reg->match(u, 0).isNull()) {
    555         // empty string matched by regexp -> empty array
    556         res->put(exec,lengthPropertyName, jsNumber(0));
    557         break;
     555        // empty string matched by regexp -> empty array
     556        res->put(exec,lengthPropertyName, jsNumber(0));
     557        break;
    558558      }
    559559      pos = 0;
    560560      while (static_cast<uint32_t>(i) != limit && pos < u.size()) {
    561         // TODO: back references
     561        // TODO: back references
    562562        int mpos;
    563563        int *ovector = 0L;
    564         UString mstr = reg->match(u, pos, &mpos, &ovector);
     564        UString mstr = reg->match(u, pos, &mpos, &ovector);
    565565        delete [] ovector; ovector = 0L;
    566         if (mpos < 0)
    567           break;
    568         pos = mpos + (mstr.isEmpty() ? 1 : mstr.size());
    569         if (mpos != p0 || !mstr.isEmpty()) {
    570           res->put(exec,i, jsString(u.substr(p0, mpos-p0)));
    571           p0 = mpos + mstr.size();
    572           i++;
    573         }
     566        if (mpos < 0)
     567          break;
     568        pos = mpos + (mstr.isEmpty() ? 1 : mstr.size());
     569        if (mpos != p0 || !mstr.isEmpty()) {
     570          res->put(exec,i, jsString(u.substr(p0, mpos-p0)));
     571          p0 = mpos + mstr.size();
     572          i++;
     573        }
    574574      }
    575575    } else {
    576576      u2 = a0->toString(exec);
    577577      if (u2.isEmpty()) {
    578         if (u.isEmpty()) {
    579           // empty separator matches empty string -> empty array
    580           put(exec,lengthPropertyName, jsNumber(0));
    581           break;
    582         } else {
    583           while (static_cast<uint32_t>(i) != limit && i < u.size()-1)
    584             res->put(exec, i++, jsString(u.substr(p0++, 1)));
    585         }
     578        if (u.isEmpty()) {
     579          // empty separator matches empty string -> empty array
     580          put(exec,lengthPropertyName, jsNumber(0));
     581          break;
     582        } else {
     583          while (static_cast<uint32_t>(i) != limit && i < u.size()-1)
     584            res->put(exec, i++, jsString(u.substr(p0++, 1)));
     585        }
    586586      } else {
    587         while (static_cast<uint32_t>(i) != limit && (pos = u.find(u2, p0)) >= 0) {
    588           res->put(exec, i, jsString(u.substr(p0, pos-p0)));
    589           p0 = pos + u2.size();
    590           i++;
    591         }
     587        while (static_cast<uint32_t>(i) != limit && (pos = u.find(u2, p0)) >= 0) {
     588          res->put(exec, i, jsString(u.substr(p0, pos-p0)));
     589          p0 = pos + u2.size();
     590          i++;
     591        }
    592592      }
    593593    }
Note: See TracChangeset for help on using the changeset viewer.