[llvm-commits] [llvm] r168211 - /llvm/trunk/include/llvm/Attributes.h

Chris Lattner clattner at apple.com
Sun Nov 25 09:06:14 PST 2012


On Nov 16, 2012, at 2:22 PM, Benjamin Kramer <benny.kra at googlemail.com> wrote:

> Author: d0k
> Date: Fri Nov 16 16:22:20 2012
> New Revision: 168211
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=168211&view=rev
> Log:
> Remove default public copy ctors.
> 
> They are just useless and prevent SmallVector from picking an optimized codepath
> for memcpyable elements.

Is this something that Clang could conceivably warn about?

-Chris

> 
> Modified:
>    llvm/trunk/include/llvm/Attributes.h
> 
> Modified: llvm/trunk/include/llvm/Attributes.h
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Attributes.h?rev=168211&r1=168210&r2=168211&view=diff
> ==============================================================================
> --- llvm/trunk/include/llvm/Attributes.h (original)
> +++ llvm/trunk/include/llvm/Attributes.h Fri Nov 16 16:22:20 2012
> @@ -92,11 +92,6 @@
>   Attributes(AttributesImpl *A) : Attrs(A) {}
> public:
>   Attributes() : Attrs(0) {}
> -  Attributes(const Attributes &A) : Attrs(A.Attrs) {}
> -  Attributes &operator=(const Attributes &A) {
> -    Attrs = A.Attrs;
> -    return *this;
> -  }
> 
>   /// get - Return a uniquified Attributes object. This takes the uniquified
>   /// value from the Builder and wraps it in the Attributes class.
> @@ -199,7 +194,6 @@
>   AttrBuilder() : Bits(0) {}
>   explicit AttrBuilder(uint64_t B) : Bits(B) {}
>   AttrBuilder(const Attributes &A) : Bits(A.Raw()) {}
> -  AttrBuilder(const AttrBuilder &B) : Bits(B.Bits) {}
> 
>   void clear() { Bits = 0; }
> 
> 
> 
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list