Changeset 11763 in webkit for trunk/JavaScriptCore/kjs/identifier.cpp
- Timestamp:
- Dec 25, 2005, 1:22:35 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/kjs/identifier.cpp
r11739 r11763 130 130 { 131 131 if (!c) 132 return pass(&UString::Rep::null);132 return &UString::Rep::null; 133 133 int length = strlen(c); 134 134 if (length == 0) 135 return pass(&UString::Rep::empty);135 return &UString::Rep::empty; 136 136 137 return pass(*identifierTable().insert<const char *, CStringTranslator>(c).first);137 return *identifierTable().insert<const char *, CStringTranslator>(c).first; 138 138 } 139 139 … … 173 173 { 174 174 if (length == 0) 175 return pass(&UString::Rep::empty);175 return &UString::Rep::empty; 176 176 177 177 UCharBuffer buf = {s, length}; 178 return pass(*identifierTable().insert<UCharBuffer, UCharBufferTranslator>(buf).first);178 return *identifierTable().insert<UCharBuffer, UCharBufferTranslator>(buf).first; 179 179 } 180 180 … … 182 182 { 183 183 if (r->isIdentifier) 184 return pass(r);184 return r; 185 185 186 186 if (r->len == 0) 187 return pass(&UString::Rep::empty);187 return &UString::Rep::empty; 188 188 189 189 UString::Rep *result = *identifierTable().insert(r).first; 190 190 if (result == r) 191 191 r->isIdentifier = true; 192 return pass(result);192 return result; 193 193 } 194 194
Note:
See TracChangeset
for help on using the changeset viewer.