From a79efd7469b229f352387bd6c597cabc9c6f83fd Mon Sep 17 00:00:00 2001 From: Reid Kleckner Date: Thu, 21 Aug 2014 23:24:08 +0000 Subject: [PATCH] Add an explicit move constructor to SrcBuffer MSVC can't synthesize the explicit one. Instead it tries to emit a copy ctor which would call the deleted copy ctor of unique_ptr. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@216244 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/Support/SourceMgr.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/llvm/Support/SourceMgr.h b/include/llvm/Support/SourceMgr.h index 19dad6b6ac5..f9e114b67cb 100644 --- a/include/llvm/Support/SourceMgr.h +++ b/include/llvm/Support/SourceMgr.h @@ -51,6 +51,11 @@ private: /// This is the location of the parent include, or null if at the top level. SMLoc IncludeLoc; + + SrcBuffer() {} + + SrcBuffer(SrcBuffer &&O) + : Buffer(std::move(O.Buffer)), IncludeLoc(O.IncludeLoc) {} }; /// This is all of the buffers that we are reading from. -- 2.34.1