From 826197cf76b85a3f0208ca2c410ce7bc92c5bb33 Mon Sep 17 00:00:00 2001 From: Matthew Hoops Date: Mon, 7 Mar 2011 13:11:28 -0500 Subject: [PATCH] COMMON: Make the operator=(String) function be a const reference instead --- common/winexe.cpp | 4 ++-- common/winexe.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/common/winexe.cpp b/common/winexe.cpp index de53ae64907..ea96cee4a0d 100644 --- a/common/winexe.cpp +++ b/common/winexe.cpp @@ -28,8 +28,8 @@ namespace Common { -WinResourceID &WinResourceID::operator=(String string) { - _name = string; +WinResourceID &WinResourceID::operator=(const String &x) { + _name = x; _idType = kIDTypeString; return *this; } diff --git a/common/winexe.h b/common/winexe.h index 3567a037e16..af0d70c5550 100644 --- a/common/winexe.h +++ b/common/winexe.h @@ -38,7 +38,7 @@ public: WinResourceID(String x) { _idType = kIDTypeString; _name = x; } WinResourceID(uint32 x) { _idType = kIDTypeNumerical; _id = x; } - WinResourceID &operator=(String string); + WinResourceID &operator=(const String &x); WinResourceID &operator=(uint32 x); bool operator==(const String &x) const;