From: Lang Hames Date: Sun, 26 Oct 2014 22:12:02 +0000 (+0000) Subject: [PBQP] Tidying up as per Dave Blaikie's suggesions for r220642. X-Git-Url: http://plrg.eecs.uci.edu/git/?p=oota-llvm.git;a=commitdiff_plain;h=ce3a612d3a63f39673b8f30f0bcecae762044dcf;ds=sidebyside [PBQP] Tidying up as per Dave Blaikie's suggesions for r220642. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220655 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/CodeGen/RegAllocPBQP.h b/include/llvm/CodeGen/RegAllocPBQP.h index 4d7e5d54d0d..b32499c3139 100644 --- a/include/llvm/CodeGen/RegAllocPBQP.h +++ b/include/llvm/CodeGen/RegAllocPBQP.h @@ -109,9 +109,9 @@ public: RS = Other.RS; NumOpts = Other.NumOpts; DeniedOpts = Other.DeniedOpts; - OptUnsafeEdges = std::unique_ptr(new unsigned[NumOpts]); - std::copy(&Other.OptUnsafeEdges[0], &Other.OptUnsafeEdges[NumOpts], - &OptUnsafeEdges[0]); + OptUnsafeEdges.reset(new unsigned[NumOpts]); + std::copy(Other.OptUnsafeEdges.get(), Other.OptUnsafeEdges.get() + NumOpts, + OptUnsafeEdges.get()); VReg = Other.VReg; OptionRegs = Other.OptionRegs; return *this;