]> git.tdb.fi Git - libs/core.git/blobdiff - source/core/variant.h
Merge branch 'strings-master'
[libs/core.git] / source / core / variant.h
index 6632831e9efa4557f777f36e03f30d416a853d0b..8d6db9a3de116e81433ac0e6fb706a3748adba50 100644 (file)
@@ -1,7 +1,7 @@
 /* $Id$
 
 This file is part of libmspcore
-Copyright © 2006-2007 Mikko Rasa, Mikkosoft Productions
+Copyright © 2008 Mikko Rasa, Mikkosoft Productions
 Distributed under the LGPL
 */
 
@@ -44,14 +44,14 @@ public:
        Variant &operator=(const T &v)
        {
                delete store;
-               store=new Store<typename RemoveConst<T>::Type>(v);
+               store = new Store<typename RemoveConst<T>::Type>(v);
                return *this;
        }
 
        Variant &operator=(const Variant &v)
        {
                delete store;
-               store=(v.store ? v.store->clone() : 0);
+               store = (v.store ? v.store->clone() : 0);
                return *this;
        }
 
@@ -59,7 +59,7 @@ public:
        T &value() const
        {
                typedef typename RemoveConst<T>::Type NCT;
-               Store<NCT> *s=dynamic_cast<Store<NCT> *>(store);
+               Store<NCT> *s = dynamic_cast<Store<NCT> *>(store);
                if(!s)
                        throw InvalidState("Type mismatch");
                return s->data;