Explorar o código

Fix another missing move in glTFCommon.h

Aaron Gokaslan %!s(int64=2) %!d(string=hai) anos
pai
achega
5a0df03d2b
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      code/AssetLib/glTF/glTFCommon.h

+ 4 - 1
code/AssetLib/glTF/glTFCommon.h

@@ -245,9 +245,12 @@ struct Nullable {
 
     Nullable() :
             isPresent(false) {}
-    Nullable(T &val) :
+    Nullable(const T &val) :
             value(val),
             isPresent(true) {}
+	Nullable(T &&val) :
+			value(std::move(val)),
+			isPresent(true) {}
 };
 
 //! A reference to one top-level object, which is valid