Changeset 58003 in webkit for trunk/JavaScriptCore/wtf/WTFThreadData.h
- Timestamp:
- Apr 21, 2010, 12:40:20 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/wtf/WTFThreadData.h
r57879 r58003 31 31 #include <wtf/HashSet.h> 32 32 #include <wtf/Noncopyable.h> 33 #include <wtf/text/StringHash.h> 33 34 34 35 // This was ENABLE(WORKERS) in WebCore, but this is not defined when compiling JSC. … … 46 47 47 48 // FIXME: This is a temporary layering violation while we move more string code to WTF. 48 namespace JSC {49 class IdentifierTable;50 }51 52 // FIXME: This is a temporary layering violation while we move more string code to WTF.53 49 namespace WebCore { 54 50 class AtomicStringTable; 51 class StringImpl; 55 52 } 53 using WebCore::StringImpl; 56 54 57 55 typedef void (*AtomicStringTableDestructor)(WebCore::AtomicStringTable*); 56 57 #if USE(JSC) 58 // FIXME: This is a temporary layering violation while we move more string code to WTF. 59 namespace JSC { 60 61 typedef HashMap<const char*, RefPtr<StringImpl>, PtrHash<const char*> > LiteralIdentifierTable; 62 63 class IdentifierTable : public FastAllocBase { 64 public: 65 ~IdentifierTable(); 66 67 std::pair<HashSet<StringImpl*>::iterator, bool> add(StringImpl* value); 68 template<typename U, typename V> 69 std::pair<HashSet<StringImpl*>::iterator, bool> add(U value); 70 71 void remove(StringImpl* r) { m_table.remove(r); } 72 73 LiteralIdentifierTable& literalTable() { return m_literalTable; } 74 75 private: 76 HashSet<StringImpl*> m_table; 77 LiteralIdentifierTable m_literalTable; 78 }; 79 80 } 81 #endif 58 82 59 83 namespace WTF {
Note:
See TracChangeset
for help on using the changeset viewer.