svn commit: r355974 - head/lib/libdevdctl

Ryan Libby rlibby at FreeBSD.org
Sat Dec 21 02:44:27 UTC 2019


Author: rlibby
Date: Sat Dec 21 02:44:26 2019
New Revision: 355974
URL: https://svnweb.freebsd.org/changeset/base/355974

Log:
  libdevdctl: g++9 avoid Wdeprecated-copy
  
  g++9 now warns about having defined an assignment operator but using the
  default copy constructor, or vice versa.  Avoid the issue in libdevdctl
  by just using the default assignment operator too.
  
  Reviewed by:	asomers, dim
  Sponsored by:	Dell EMC Isilon
  Differential Revision:	https://reviews.freebsd.org/D22887

Modified:
  head/lib/libdevdctl/guid.h

Modified: head/lib/libdevdctl/guid.h
==============================================================================
--- head/lib/libdevdctl/guid.h	Sat Dec 21 02:44:13 2019	(r355973)
+++ head/lib/libdevdctl/guid.h	Sat Dec 21 02:44:26 2019	(r355974)
@@ -70,9 +70,6 @@ class Guid (public)
 	Guid(const std::string &guid);
 	static Guid InvalidGuid();
 
-	/* Assignment */
-	Guid& operator=(const Guid& rhs);
-
 	/* Test the validity of this guid. */
 	bool IsValid()			 const;
 
@@ -108,13 +105,6 @@ inline Guid
 Guid::InvalidGuid()
 {
 	return (Guid(INVALID_GUID));
-}
-
-inline Guid&
-Guid::operator=(const Guid &rhs)
-{
-	m_GUID = rhs.m_GUID;
-	return (*this);
 }
 
 inline bool


More information about the svn-src-all mailing list