| Index: third_party/WebKit/Source/wtf/text/AtomicString.cpp
|
| diff --git a/third_party/WebKit/Source/wtf/text/AtomicString.cpp b/third_party/WebKit/Source/wtf/text/AtomicString.cpp
|
| index 2885ad1be673344508dd790079d17c19905bf23c..c4f7d2cefa9270f2bd48b6e91621d1a0e66f07fb 100644
|
| --- a/third_party/WebKit/Source/wtf/text/AtomicString.cpp
|
| +++ b/third_party/WebKit/Source/wtf/text/AtomicString.cpp
|
| @@ -125,16 +125,6 @@ static inline PassRefPtr<StringImpl> addToStringTable(const T& value)
|
| return addResult.isNewEntry ? adoptRef(*addResult.storedValue) : *addResult.storedValue;
|
| }
|
|
|
| -PassRefPtr<StringImpl> AtomicString::add(const LChar* c)
|
| -{
|
| - if (!c)
|
| - return nullptr;
|
| - if (!*c)
|
| - return StringImpl::empty();
|
| -
|
| - return add(c, strlen(reinterpret_cast<const char*>(c)));
|
| -}
|
| -
|
| template<typename CharacterType>
|
| struct HashTranslatorCharBuffer {
|
| const CharacterType* s;
|
| @@ -367,26 +357,6 @@ struct LCharBufferTranslator {
|
| }
|
| };
|
|
|
| -typedef HashTranslatorCharBuffer<char> CharBuffer;
|
| -struct CharBufferFromLiteralDataTranslator {
|
| - static unsigned hash(const CharBuffer& buf)
|
| - {
|
| - return StringHasher::computeHashAndMaskTop8Bits(reinterpret_cast<const LChar*>(buf.s), buf.length);
|
| - }
|
| -
|
| - static bool equal(StringImpl* const& str, const CharBuffer& buf)
|
| - {
|
| - return WTF::equal(str, buf.s, buf.length);
|
| - }
|
| -
|
| - static void translate(StringImpl*& location, const CharBuffer& buf, unsigned hash)
|
| - {
|
| - location = StringImpl::create(buf.s, buf.length).leakRef();
|
| - location->setHash(hash);
|
| - location->setIsAtomic(true);
|
| - }
|
| -};
|
| -
|
| PassRefPtr<StringImpl> AtomicString::add(const LChar* s, unsigned length)
|
| {
|
| if (!s)
|
| @@ -399,15 +369,6 @@ PassRefPtr<StringImpl> AtomicString::add(const LChar* s, unsigned length)
|
| return addToStringTable<LCharBuffer, LCharBufferTranslator>(buffer);
|
| }
|
|
|
| -PassRefPtr<StringImpl> AtomicString::addFromLiteralData(const char* characters, unsigned length)
|
| -{
|
| - ASSERT(characters);
|
| - ASSERT(length);
|
| -
|
| - CharBuffer buffer = { characters, length };
|
| - return addToStringTable<CharBuffer, CharBufferFromLiteralDataTranslator>(buffer);
|
| -}
|
| -
|
| PassRefPtr<StringImpl> AtomicString::addSlowCase(StringImpl* string)
|
| {
|
| return atomicStringTable().addStringImpl(string);
|
|
|