From: Mikko Rasa Date: Tue, 17 Sep 2019 16:13:04 +0000 (+0300) Subject: Add copy-constructor as required by C++11 X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=22907c578cb8244c60e8ab1b3466340768491dd1;p=builder.git Add copy-constructor as required by C++11 --- diff --git a/source/buildinfo.h b/source/buildinfo.h index ccfa2b6..fa8ae62 100644 --- a/source/buildinfo.h +++ b/source/buildinfo.h @@ -71,6 +71,7 @@ public: public: Tracked(): value(T()), set(false) { } Tracked(T v): value(v), set(false) { } + Tracked(const Tracked &t): value(t.value), set(t.set) { } Tracked &operator=(const Tracked &v) { if(v.set) { value = v.value; set = true; } return *this; } Tracked &operator=(const T &v) { value = v; set = true; return *this; }