Workaround MSVC not providing implicit move members
authorDavid Blaikie <dblaikie@gmail.com>
Wed, 4 Mar 2015 02:07:51 +0000 (02:07 +0000)
committerDavid Blaikie <dblaikie@gmail.com>
Wed, 4 Mar 2015 02:07:51 +0000 (02:07 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@231204 91177308-0d34-0410-b5e6-96231b3b80d8

lib/AsmParser/LLParser.h

index 3675d958323a9bb08fb00f9620fe4910bbe3d5cc..da3d02f9e5eac412b818dc098aaf232e5eddc137 100644 (file)
@@ -65,6 +65,14 @@ namespace llvm {
     std::unique_ptr<Constant*[]> ConstantStructElts;
 
     ValID() : Kind(t_LocalID), APFloatVal(0.0) {}
+    // Workaround for MSVC not synthesizing implicit move members.
+    ValID(ValID &&RHS)
+        : Kind(std::move(RHS.Kind)), Loc(std::move(RHS.Loc)),
+          UIntVal(std::move(RHS.UIntVal)), StrVal(std::move(RHS.StrVal)),
+          StrVal2(std::move(RHS.StrVal2)), APSIntVal(std::move(RHS.APSIntVal)),
+          APFloatVal(std::move(RHS.APFloatVal)),
+          ConstantVal(std::move(RHS.ConstantVal)),
+          ConstantStructElts(std::move(RHS.ConstantStructElts)) {}
 
     bool operator<(const ValID &RHS) const {
       if (Kind == t_LocalID || Kind == t_GlobalID)