Changeset 2772 in webkit for trunk/JavaScriptCore/kjs/identifier.h
- Timestamp:
- Nov 19, 2002, 6:35:01 PM (23 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/kjs/identifier.h
r2769 r2772 31 31 public: 32 32 Identifier() { } 33 Identifier(const char *s) : _ustring(s) { } 34 Identifier(const UString &s) : _ustring(s) { } 33 Identifier(const char *s) : _ustring(add(s)) { } 34 Identifier(const UChar *s, int length) : _ustring(add(s, length)) { } 35 explicit Identifier(const UString &s) : _ustring(add(s)) { } 35 36 36 37 const UString &ustring() const { return _ustring; } … … 43 44 const char *ascii() const { return _ustring.ascii(); } 44 45 45 static Identifier from(unsigned y) { return UString::from(y); }46 static Identifier from(unsigned y) { return Identifier(UString::from(y)); } 46 47 47 48 bool isNull() const { return _ustring.isNull(); } … … 58 59 friend bool operator==(const Identifier &, const char *); 59 60 60 static void aboutToDestroyUStringRep(UString::Rep *);61 static void remove(UString::Rep *); 61 62 62 63 private: 64 static UString::Rep *add(const char *); 65 static UString::Rep *add(const UChar *, int length); 66 static UString::Rep *add(const UString &); 67 63 68 UString _ustring; 64 69 }; … … 74 79 } 75 80 81 extern const Identifier argumentsPropertyName; 82 extern const Identifier calleePropertyName; 83 extern const Identifier constructorPropertyName; 84 extern const Identifier lengthPropertyName; 85 extern const Identifier messagePropertyName; 86 extern const Identifier namePropertyName; 87 extern const Identifier prototypePropertyName; 88 extern const Identifier specialPrototypePropertyName; 89 extern const Identifier toLocaleStringPropertyName; 90 extern const Identifier toStringPropertyName; 91 extern const Identifier valueOfPropertyName; 92 76 93 } 77 94
Note:
See TracChangeset
for help on using the changeset viewer.