On 08/02/2017 12:19 PM, Yao Qi wrote: > On Wed, Jul 26, 2017 at 9:55 AM, Yao Qi <qiyao...@gmail.com> wrote: >> On 17-07-19 10:30:45, Yao Qi wrote: >>> We have many classes that copy cotr and assignment operator are deleted >>> in different projects, gcc, gdb and gold. So this patch adds a macro >>> to do this, and replace these existing mechanical code with macro >>> DISABLE_COPY_AND_ASSIGN. >>> >>> The patch was posted in gdb-patches, >>> https://sourceware.org/ml/gdb-patches/2017-07/msg00254.html but we >>> think it is better to put this macro in include/ansidecl.h so that >>> other projects can use it too. >>> >>> Boostrapped on x86_64-linux-gnu. Is it OK? >>> >>> include: >>> >>> 2017-07-19 Yao Qi <yao...@linaro.org> >>> Pedro Alves <pal...@redhat.com> >>> >>> * ansidecl.h (DISABLE_COPY_AND_ASSIGN): New macro. >>> >>> gcc/cp: >>> >>> 2017-07-19 Yao Qi <yao...@linaro.org> >>> >>> * cp-tree.h (class ovl_iterator): Use DISABLE_COPY_AND_ASSIGN. >>> * name-lookup.c (struct name_loopup): Likewise. >>> >>> gcc: >>> >>> 2017-07-19 Yao Qi <yao...@linaro.org> >>> >>> * tree-ssa-scopedtables.h (class avail_exprs_stack): Use >>> DISABLE_COPY_AND_ASSIGN. >>> (class const_and_copies): Likewise. >> >> Ping. >> https://gcc.gnu.org/ml/gcc-patches/2017-07/msg01134.html >> > > Ping. It is a quite straightforward patch, can any one > take a look? >
Yeah, this is a macro that lots of projects out there reinvent, can't imagine it being very controversial. I could have used this today in another spot in gdb. The patch as is touches areas with different maintainers, it may have fallen victim of diffusion of responsibility. Could we get at least the ansidecl.h change in, so we can start using it in gdb? CCing Ian as a libiberty maintainer. Thanks, Pedro Alves