]> git.tdb.fi Git - libs/core.git/blobdiff - source/core/variant.h
Use default member initializers and constructor delegation
[libs/core.git] / source / core / variant.h
index 5109dbcc11811ac8297f71e3903a1eb8c4f36f36..05a8139c679783000f9e56d65ae6674029931d49 100644 (file)
@@ -50,10 +50,10 @@ private:
                { return false; }
        };
 
-       StoreBase *store;
+       StoreBase *store = 0;
 
 public:
-       Variant(): store(0) { }
+       Variant() { }
        template<typename T>
        Variant(const T &v): store(new Store<typename std::remove_cv<T>::type>(v)) { }
        Variant(const Variant &v): store(v.store ? v.store->clone() : 0) { }