]> git.ipfire.org Git - thirdparty/gcc.git/commit
[include] Add macro DISABLE_COPY_AND_ASSIGN
authorqiyao <qiyao@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 15 Sep 2017 15:40:50 +0000 (15:40 +0000)
committerqiyao <qiyao@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 15 Sep 2017 15:40:50 +0000 (15:40 +0000)
commitead428aa33a5a3391b09e7006378d41eb028ce09
treedfc46c853b094c05f63c142a46308c2f86a5503d
parenta9901f70639b0c392508967975354a850b1e0625
[include] Add macro DISABLE_COPY_AND_ASSIGN

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.

include:

2017-09-15  Yao Qi  <yao.qi@linaro.org>
    Pedro Alves  <palves@redhat.com>

* ansidecl.h (DISABLE_COPY_AND_ASSIGN): New macro.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@252823 138bc75d-0d04-0410-961f-82ee72b054a4
include/ChangeLog
include/ansidecl.h