diff options
Diffstat (limited to 'lldb/source/Host/common/FileSystem.cpp')
-rw-r--r-- | lldb/source/Host/common/FileSystem.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lldb/source/Host/common/FileSystem.cpp b/lldb/source/Host/common/FileSystem.cpp index 5153a0a9..00919fe 100644 --- a/lldb/source/Host/common/FileSystem.cpp +++ b/lldb/source/Host/common/FileSystem.cpp @@ -35,6 +35,7 @@ #include <algorithm> #include <fstream> +#include <memory> #include <optional> #include <vector> @@ -288,8 +289,7 @@ FileSystem::CreateWritableDataBuffer(const llvm::Twine &path, uint64_t size, is_volatile); if (!buffer) return {}; - return std::shared_ptr<WritableDataBufferLLVM>( - new WritableDataBufferLLVM(std::move(buffer))); + return std::make_shared<WritableDataBufferLLVM>(std::move(buffer)); } std::shared_ptr<DataBuffer> @@ -300,7 +300,7 @@ FileSystem::CreateDataBuffer(const llvm::Twine &path, uint64_t size, GetMemoryBuffer<llvm::MemoryBuffer>(path, size, offset, is_volatile); if (!buffer) return {}; - return std::shared_ptr<DataBufferLLVM>(new DataBufferLLVM(std::move(buffer))); + return std::make_shared<DataBufferLLVM>(std::move(buffer)); } std::shared_ptr<WritableDataBuffer> |