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

Unified Diff: third_party/WebKit/Source/bindings/tests/results/core/UnrestrictedDoubleOrString.h

Issue 2897603003: Get and return String by const-ref if used as rvalue (Closed)
Patch Set: Created 3 years, 7 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/bindings/tests/results/core/UnrestrictedDoubleOrString.h
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/UnrestrictedDoubleOrString.h b/third_party/WebKit/Source/bindings/tests/results/core/UnrestrictedDoubleOrString.h
index 3c7868c5e4902d426bc278c2f24af0cb3b719ef0..8ed4f01a2d69502f2c6eb19666ff308336dbdc2e 100644
--- a/third_party/WebKit/Source/bindings/tests/results/core/UnrestrictedDoubleOrString.h
+++ b/third_party/WebKit/Source/bindings/tests/results/core/UnrestrictedDoubleOrString.h
@@ -28,9 +28,9 @@ class CORE_EXPORT UnrestrictedDoubleOrString final {
bool isNull() const { return m_type == SpecificTypeNone; }
bool isString() const { return m_type == SpecificTypeString; }
- String getAsString() const;
- void setString(String);
- static UnrestrictedDoubleOrString fromString(String);
+ const String& getAsString() const;
+ void setString(const String&);
+ static UnrestrictedDoubleOrString fromString(const String&);
bool isUnrestrictedDouble() const { return m_type == SpecificTypeUnrestrictedDouble; }
double getAsUnrestrictedDouble() const;

Powered by Google App Engine
This is Rietveld 408576698