From 4264840b48cb37430322c336a38506eaef1d2dc0 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Wed, 12 Aug 2015 23:16:55 +0000 Subject: [PATCH] Wdeprecated: CGBuilderInserter is copy constructed in some contexts - remove the unnecessarily disabling copy assignment to enable this The object has very simple state, there seems no reason to disallow all the usual value semantic operations. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@244831 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/CGBuilder.h | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/lib/CodeGen/CGBuilder.h b/lib/CodeGen/CGBuilder.h index 6610659131..fb36b8b5f1 100644 --- a/lib/CodeGen/CGBuilder.h +++ b/lib/CodeGen/CGBuilder.h @@ -22,9 +22,9 @@ class CodeGenFunction; /// instructions. template class CGBuilderInserter - : protected llvm::IRBuilderDefaultInserter { + : protected llvm::IRBuilderDefaultInserter { public: - CGBuilderInserter() : CGF(nullptr) {} + CGBuilderInserter() = default; explicit CGBuilderInserter(CodeGenFunction *CGF) : CGF(CGF) {} protected: @@ -33,9 +33,7 @@ protected: llvm::BasicBlock *BB, llvm::BasicBlock::iterator InsertPt) const; private: - void operator=(const CGBuilderInserter &) = delete; - - CodeGenFunction *CGF; + CodeGenFunction *CGF = nullptr; }; // Don't preserve names on values in an optimized build. -- 2.40.0