[FYI] Use DISABLE_COPY_AND_ASSIGN in minimal_symbol_reader

Message ID 20181227193341.21234-1-tom@tromey.com
State New
Headers show
Series
  • [FYI] Use DISABLE_COPY_AND_ASSIGN in minimal_symbol_reader
Related show

Commit Message

Tom Tromey Dec. 27, 2018, 7:33 p.m.
This changes minimal_symbol_reader to use DISABLE_COPY_AND_ASSIGN,
rather than the manual approach it currently uses.

Tested by rebuilding.

gdb/ChangeLog
2018-12-27  Tom Tromey  <tom@tromey.com>

	* minsyms.h (class minimal_symbol_reader): Use
	DISABLE_COPY_AND_ASSIGN.
---
 gdb/ChangeLog | 5 +++++
 gdb/minsyms.h | 5 +----
 2 files changed, 6 insertions(+), 4 deletions(-)

-- 
2.17.2

Patch

diff --git a/gdb/minsyms.h b/gdb/minsyms.h
index f6799ef00c..9e8e4c75ea 100644
--- a/gdb/minsyms.h
+++ b/gdb/minsyms.h
@@ -128,10 +128,7 @@  class minimal_symbol_reader
 
  private:
 
-  /* No need for these.  They are intentionally not defined anywhere.  */
-  minimal_symbol_reader &operator=
-    (const minimal_symbol_reader &);
-  minimal_symbol_reader (const minimal_symbol_reader &);
+  DISABLE_COPY_AND_ASSIGN (minimal_symbol_reader);
 
   struct objfile *m_objfile;