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

Unified Diff: third_party/WebKit/Source/core/dom/StyleChangeReason.cpp

Issue 1844223002: Literal AtomicString construction can rely on strlen optimization. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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
Index: third_party/WebKit/Source/core/dom/StyleChangeReason.cpp
diff --git a/third_party/WebKit/Source/core/dom/StyleChangeReason.cpp b/third_party/WebKit/Source/core/dom/StyleChangeReason.cpp
index 1c8c8b0027a89e3ad7592279422f6f3032178892..c7bac2ddaf89aff4ffa9cf75a5eead24da219814 100644
--- a/third_party/WebKit/Source/core/dom/StyleChangeReason.cpp
+++ b/third_party/WebKit/Source/core/dom/StyleChangeReason.cpp
@@ -59,12 +59,12 @@ void init()
{
ASSERT(isMainThread());
- new (NotNull, (void*)&Active) AtomicString(":active", AtomicString::ConstructFromLiteral);
- new (NotNull, (void*)&Disabled) AtomicString(":disabled", AtomicString::ConstructFromLiteral);
- new (NotNull, (void*)&Focus) AtomicString(":focus", AtomicString::ConstructFromLiteral);
- new (NotNull, (void*)&Hover) AtomicString(":hover", AtomicString::ConstructFromLiteral);
- new (NotNull, (void*)&Past) AtomicString(":past", AtomicString::ConstructFromLiteral);
- new (NotNull, (void*)&Unresolved) AtomicString(":unresolved", AtomicString::ConstructFromLiteral);
+ new (NotNull, (void*)&Active) AtomicString(":active");
+ new (NotNull, (void*)&Disabled) AtomicString(":disabled");
+ new (NotNull, (void*)&Focus) AtomicString(":focus");
+ new (NotNull, (void*)&Hover) AtomicString(":hover");
+ new (NotNull, (void*)&Past) AtomicString(":past");
+ new (NotNull, (void*)&Unresolved) AtomicString(":unresolved");
}
} // namespace StyleChangeExtraData

Powered by Google App Engine
This is Rietveld 408576698