[Scummvm-git-logs] scummvm master -> b9b6fc61513e0a1463ec3c368afcef372dd4b1ef

digitall 547637+digitall at users.noreply.github.com
Sun Mar 14 17:24:19 UTC 2021


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
b9b6fc6151 GLK: QUEST: Fix GCC Warning for Implicit Copy Operator


Commit: b9b6fc61513e0a1463ec3c368afcef372dd4b1ef
    https://github.com/scummvm/scummvm/commit/b9b6fc61513e0a1463ec3c368afcef372dd4b1ef
Author: D G Turner (digitall at scummvm.org)
Date: 2021-03-14T17:22:39Z

Commit Message:
GLK: QUEST: Fix GCC Warning for Implicit Copy Operator

This is emitted when -Wdeprecated-copy is enabled. The fix implemented
is to implement the copy operator as per the expected default.

This has the advantage of working with compilers prior to C++-11.

Changed paths:
    engines/glk/quest/string.h


diff --git a/engines/glk/quest/string.h b/engines/glk/quest/string.h
index 43f6ab602b..bb92a595e7 100644
--- a/engines/glk/quest/string.h
+++ b/engines/glk/quest/string.h
@@ -46,6 +46,8 @@ public:
 	String(const String &str) : Common::String(str) {}
 	explicit String(char c) : Common::String(c) {}
 
+	String& operator=(const String &str) { this->Common::String::operator=(str); return *this; }
+
 	char &operator[](int idx) {
 		assert(_str && idx >= 0 && idx < (int)_size);
 		return _str[idx];




More information about the Scummvm-git-logs mailing list