Title: [128895] trunk/Tools
- Revision
- 128895
- Author
- [email protected]
- Date
- 2012-09-18 08:00:45 -0700 (Tue, 18 Sep 2012)
Log Message
[WK2][WTR] InjectedBundle::booleanForKey() should handle literals effectively
https://bugs.webkit.org/show_bug.cgi?id=97014
Patch by Mikhail Pozdnyakov <[email protected]> on 2012-09-18
Reviewed by Kenneth Rohde Christiansen.
According to http://trac.webkit.org/wiki/EfficientStrings WTF::StringBuilder::appendLiteral() shall
be used for literals rather than WTF::StringBuilder::append().
* WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
(WTR::InjectedBundle::booleanForKey):
Modified Paths
Diff
Modified: trunk/Tools/ChangeLog (128894 => 128895)
--- trunk/Tools/ChangeLog 2012-09-18 14:57:14 UTC (rev 128894)
+++ trunk/Tools/ChangeLog 2012-09-18 15:00:45 UTC (rev 128895)
@@ -1,3 +1,16 @@
+2012-09-18 Mikhail Pozdnyakov <[email protected]>
+
+ [WK2][WTR] InjectedBundle::booleanForKey() should handle literals effectively
+ https://bugs.webkit.org/show_bug.cgi?id=97014
+
+ Reviewed by Kenneth Rohde Christiansen.
+
+ According to http://trac.webkit.org/wiki/EfficientStrings WTF::StringBuilder::appendLiteral() shall
+ be used for literals rather than WTF::StringBuilder::append().
+
+ * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
+ (WTR::InjectedBundle::booleanForKey):
+
2012-09-18 Simon Hausmann <[email protected]>
Update my e-mail address.
Modified: trunk/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp (128894 => 128895)
--- trunk/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp 2012-09-18 14:57:14 UTC (rev 128894)
+++ trunk/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp 2012-09-18 15:00:45 UTC (rev 128895)
@@ -209,9 +209,9 @@
WKRetainPtr<WKStringRef> wkKey(AdoptWK, WKStringCreateWithUTF8CString(key));
WKTypeRef value = WKDictionaryGetItemForKey(dictionary, wkKey.get());
if (WKGetTypeID(value) != WKBooleanGetTypeID()) {
- stringBuilder()->append("Boolean value for key \"");
+ stringBuilder()->appendLiteral("Boolean value for key \"");
stringBuilder()->append(key);
- stringBuilder()->append("\" not found in dictionary\n");
+ stringBuilder()->appendLiteral("\" not found in dictionary\n");
return false;
}
return WKBooleanGetValue(static_cast<WKBooleanRef>(value));
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes