Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1523)

Unified Diff: Source/wtf/text/AtomicString.h

Issue 354023003: Add move constructor and assignment operator to RefPtr class (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Take Nico's feedback into consideration Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« Source/wtf/RefPtr.h ('K') | « Source/wtf/RefPtr.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/wtf/text/AtomicString.h
diff --git a/Source/wtf/text/AtomicString.h b/Source/wtf/text/AtomicString.h
index 8983dcdced2527b02b55891b3c4724cf3ac5de15..447069d2df73e724c3636e50e3a1ac8232161db3 100644
--- a/Source/wtf/text/AtomicString.h
+++ b/Source/wtf/text/AtomicString.h
@@ -69,17 +69,6 @@ public:
COMPILE_ASSERT((charactersCount - 1 <= ((unsigned(~0) - sizeof(StringImpl)) / sizeof(LChar))), AtomicStringFromLiteralCannotOverflow);
}
-#if COMPILER_SUPPORTS(CXX_RVALUE_REFERENCES)
- // We have to declare the copy constructor and copy assignment operator as well, otherwise
- // they'll be implicitly deleted by adding the move constructor and move assignment operator.
- // FIXME: Instead of explicitly casting to String&& here, we should use std::move, but that requires us to
- // have a standard library that supports move semantics.
- AtomicString(const AtomicString& other) : m_string(other.m_string) { }
- AtomicString(AtomicString&& other) : m_string(static_cast<String&&>(other.m_string)) { }
- AtomicString& operator=(const AtomicString& other) { m_string = other.m_string; return *this; }
- AtomicString& operator=(AtomicString&& other) { m_string = static_cast<String&&>(other.m_string); return *this; }
-#endif
-
// Hash table deleted values, which are only constructed and never copied or destroyed.
AtomicString(WTF::HashTableDeletedValueType) : m_string(WTF::HashTableDeletedValue) { }
bool isHashTableDeletedValue() const { return m_string.isHashTableDeletedValue(); }
« Source/wtf/RefPtr.h ('K') | « Source/wtf/RefPtr.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698