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

Unified Diff: Source/core/dom/QualifiedName.h

Issue 1304043002: Make classes and structures in core/dom fast-allocated. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 4 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
« no previous file with comments | « Source/core/dom/NthIndexCache.h ('k') | Source/core/dom/ScopedWindowFocusAllowedIndicator.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/QualifiedName.h
diff --git a/Source/core/dom/QualifiedName.h b/Source/core/dom/QualifiedName.h
index a0266fca9bfcabd28bc12192fb29befb9d4c5e2a..0e48ab795b37d78d8412be7fbf1108f1d229128b 100644
--- a/Source/core/dom/QualifiedName.h
+++ b/Source/core/dom/QualifiedName.h
@@ -22,6 +22,7 @@
#define QualifiedName_h
#include "core/CoreExport.h"
+#include "wtf/Allocator.h"
#include "wtf/HashTableDeletedValueType.h"
#include "wtf/HashTraits.h"
#include "wtf/RefCounted.h"
@@ -30,6 +31,7 @@
namespace blink {
struct QualifiedNameComponents {
+ DISALLOW_ALLOCATION();
StringImpl* m_prefix;
StringImpl* m_localName;
StringImpl* m_namespace;
@@ -38,6 +40,7 @@ struct QualifiedNameComponents {
// This struct is used to pass data between QualifiedName and the QNameTranslator.
// For hashing and equality only the QualifiedNameComponents fields are used.
struct QualifiedNameData {
+ DISALLOW_ALLOCATION();
QualifiedNameComponents m_components;
bool m_isStatic;
};
@@ -153,6 +156,7 @@ inline unsigned hashComponents(const QualifiedNameComponents& buf)
}
struct QualifiedNameHash {
+ STATIC_ONLY(QualifiedNameHash);
static unsigned hash(const QualifiedName& name) { return hash(name.impl()); }
static unsigned hash(const QualifiedName::QualifiedNameImpl* name)
« no previous file with comments | « Source/core/dom/NthIndexCache.h ('k') | Source/core/dom/ScopedWindowFocusAllowedIndicator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698