Good catch. I updated the change excluding private operators too.

On Mon, Dec 15, 2014 at 3:58 PM, Aaron Ballman <[email protected]>
wrote:

> On Mon, Dec 15, 2014 at 3:22 PM, Samuel Benzaquen <[email protected]>
> wrote:
> > Hi alexfh,
> >
> > Warn when the return type of assign operators is not Class&.
> >
> > http://reviews.llvm.org/D6667
> >
> > Files:
> >   clang-tidy/google/AssignOperatorSignatureCheck.cpp
> >   clang-tidy/google/AssignOperatorSignatureCheck.h
> >   clang-tidy/google/CMakeLists.txt
> >   clang-tidy/google/GoogleTidyModule.cpp
> >   test/clang-tidy/google-assign-operator.cpp
> >
> > EMAIL PREFERENCES
> >   http://reviews.llvm.org/settings/panel/emailpreferences/
>
> +struct Deleted {
> +  // We don't check the return value of deleted operators.
> +  void operator=(const Deleted&) = delete;
> +  void operator=(Deleted&&) = delete;
> +};
>
> What about private declarations without a definition? Eg)
>
> class noncopyable {
>   noncopyable(const noncopyable&);
>   void operator=(const noncopyable&);
> };
>
> ~Aaron
>
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to