diff --git a/doc/CHANGELOG.md b/doc/CHANGELOG.md index 16ee7c38..996158ee 100644 --- a/doc/CHANGELOG.md +++ b/doc/CHANGELOG.md @@ -107,6 +107,7 @@ The full set of tests is only run for tagged releases. - use std::shared_ptr instead of boost - use std::function instead of boost - use std::bind or in most cases a lambda instead of boost::bind + - use =delete for noncopyable instead of boost - reduce usage of pointers in APIs - add HasPort/HasVirt(); Port() and Virt() return reference - rw11/shell.tcl: add workaround for tclreadline and `after` interference diff --git a/tools/src/librlink/ReventFd.hpp b/tools/src/librlink/ReventFd.hpp index c647f9dc..796001a8 100644 --- a/tools/src/librlink/ReventFd.hpp +++ b/tools/src/librlink/ReventFd.hpp @@ -1,6 +1,6 @@ -// $Id: ReventFd.hpp 983 2018-01-02 20:35:59Z mueller $ +// $Id: ReventFd.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2013- by Walter F.J. Mueller +// Copyright 2013-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.0.1 use =delete for noncopyable instead of boost // 2013-01-14 475 1.0 Initial version // 2013-01-11 473 0.5 First draft // --------------------------------------------------------------------------- @@ -26,15 +27,16 @@ #ifndef included_Retro_ReventFd #define included_Retro_ReventFd 1 -#include "boost/utility.hpp" - namespace Retro { - class ReventFd : private boost::noncopyable { + class ReventFd { public: ReventFd(); virtual ~ReventFd(); + ReventFd(const ReventFd&) = delete; // noncopyable + ReventFd& operator=(const ReventFd&) = delete; // noncopyable + int Fd() const; int Signal(); int Wait(); diff --git a/tools/src/librlink/ReventLoop.hpp b/tools/src/librlink/ReventLoop.hpp index c863ffa3..72d392d5 100644 --- a/tools/src/librlink/ReventLoop.hpp +++ b/tools/src/librlink/ReventLoop.hpp @@ -1,4 +1,4 @@ -// $Id: ReventLoop.hpp 1083 2018-12-15 19:19:16Z mueller $ +// $Id: ReventLoop.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2013-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.2.5 use =delete for noncopyable instead of boost // 2018-12-15 1083 1.2.4 AddPollHandler(): use rval ref and move // 2018-12-14 1081 1.2.3 use std::function instead of boost // 2018-12-07 1078 1.2.2 use std::shared_ptr instead of boost @@ -39,20 +40,22 @@ #include #include -#include "boost/utility.hpp" #include "boost/thread/mutex.hpp" #include "librtools/RlogFile.hpp" namespace Retro { - class ReventLoop : private boost::noncopyable { + class ReventLoop { public: typedef std::function pollhdl_t; ReventLoop(); virtual ~ReventLoop(); + ReventLoop(const ReventLoop&) = delete; // noncopyable + ReventLoop& operator=(const ReventLoop&) = delete; // noncopyable + void AddPollHandler(pollhdl_t&& pollhdl, int fd, short events=POLLIN); bool TestPollHandler(int fd, short events=POLLIN); diff --git a/tools/src/librlink/RlinkConnect.hpp b/tools/src/librlink/RlinkConnect.hpp index 17512de4..b8cadccb 100644 --- a/tools/src/librlink/RlinkConnect.hpp +++ b/tools/src/librlink/RlinkConnect.hpp @@ -1,4 +1,4 @@ -// $Id: RlinkConnect.hpp 1079 2018-12-09 10:56:59Z mueller $ +// $Id: RlinkConnect.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2011-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 2.8.1 use =delete for noncopyable instead of boost // 2018-12-08 1079 2.8 add HasPort(); return ref for Port() // 2018-12-07 1078 2.7.1 use std::shared_ptr instead of boost // 2018-12-01 1076 2.7 use unique_ptr instead of scoped_ptr @@ -58,7 +59,6 @@ #include #include -#include "boost/utility.hpp" #include "boost/thread/recursive_mutex.hpp" #include "librtools/RerrMsg.hpp" @@ -79,12 +79,15 @@ namespace Retro { class RlinkServer; // forw decl to avoid circular incl - class RlinkConnect : public Rbits, private boost::noncopyable { + class RlinkConnect : public Rbits { public: RlinkConnect(); ~RlinkConnect(); + RlinkConnect(const RlinkConnect&) = delete; // noncopyable + RlinkConnect& operator=(const RlinkConnect&) = delete; // noncopyable + bool Open(const std::string& name, RerrMsg& emsg); void Close(); bool IsOpen() const; diff --git a/tools/src/librlink/RlinkPacketBuf.hpp b/tools/src/librlink/RlinkPacketBuf.hpp index 07075f8b..fa0ec568 100644 --- a/tools/src/librlink/RlinkPacketBuf.hpp +++ b/tools/src/librlink/RlinkPacketBuf.hpp @@ -1,6 +1,6 @@ -// $Id: RlinkPacketBuf.hpp 983 2018-01-02 20:35:59Z mueller $ +// $Id: RlinkPacketBuf.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2011-2017 by Walter F.J. Mueller +// Copyright 2011-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 2.0.2 use =delete for noncopyable instead of boost // 2017-04-07 868 2.0.1 Dump(): add detail arg // 2014-11-23 606 2.0 re-organize for rlink v4 // 2013-04-21 509 1.0.2 add SndAttn() method @@ -34,20 +35,21 @@ #include #include -#include "boost/utility.hpp" - #include "librtools/Rstats.hpp" #include "RlinkCrc16.hpp" namespace Retro { - class RlinkPacketBuf : private boost::noncopyable { + class RlinkPacketBuf { public: RlinkPacketBuf(); ~RlinkPacketBuf(); + RlinkPacketBuf(const RlinkPacketBuf&) = delete; // noncopy + RlinkPacketBuf& operator=(const RlinkPacketBuf&) = delete; // noncopyable + size_t PktSize() const; uint32_t Flags() const; diff --git a/tools/src/librlink/RlinkPort.hpp b/tools/src/librlink/RlinkPort.hpp index ababc3b0..0f72e244 100644 --- a/tools/src/librlink/RlinkPort.hpp +++ b/tools/src/librlink/RlinkPort.hpp @@ -1,4 +1,4 @@ -// $Id: RlinkPort.hpp 1078 2018-12-08 14:19:03Z mueller $ +// $Id: RlinkPort.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2011-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.4.4 use =delete for noncopyable instead of boost // 2018-12-07 1078 1.4.3 use std::shared_ptr instead of boost // 2018-12-01 1076 1.4 2 use unique_ptr // 2017-04-07 868 1.4.1 Dump(): add detail arg @@ -42,8 +43,6 @@ #include #include -#include "boost/utility.hpp" - #include "librtools/RerrMsg.hpp" #include "librtools/RlogFile.hpp" #include "librtools/Rstats.hpp" @@ -52,13 +51,16 @@ namespace Retro { - class RlinkPort : private boost::noncopyable { + class RlinkPort { public: typedef std::unique_ptr port_uptr_t; RlinkPort(); virtual ~RlinkPort(); + RlinkPort(const RlinkPort&) = delete; // noncopyable + RlinkPort& operator=(const RlinkPort&) = delete; // noncopyable + virtual bool Open(const std::string& url, RerrMsg& emsg) = 0; virtual void Close(); diff --git a/tools/src/librlink/RlinkServer.hpp b/tools/src/librlink/RlinkServer.hpp index baa4762a..78025704 100644 --- a/tools/src/librlink/RlinkServer.hpp +++ b/tools/src/librlink/RlinkServer.hpp @@ -1,4 +1,4 @@ -// $Id: RlinkServer.hpp 1083 2018-12-15 19:19:16Z mueller $ +// $Id: RlinkServer.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2013-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 2.2.5 use =delete for noncopyable instead of boost // 2018-12-15 1083 2.2.4 for std::function setups: use rval ref and move // 2018-12-14 1081 2.2.3 use std::function instead of boost // 2018-12-07 1078 2.2.2 use std::shared_ptr instead of boost @@ -42,7 +43,6 @@ #include #include -#include "boost/utility.hpp" #include "boost/thread/thread.hpp" #include "librtools/Rstats.hpp" @@ -54,7 +54,7 @@ namespace Retro { - class RlinkServer : private boost::noncopyable { + class RlinkServer { public: struct AttnArgs { @@ -72,6 +72,9 @@ namespace Retro { explicit RlinkServer(); virtual ~RlinkServer(); + + RlinkServer(const RlinkServer&) = delete; // noncopyable + RlinkServer& operator=(const RlinkServer&) = delete; // noncopyable void SetConnect(const std::shared_ptr& spconn); const std::shared_ptr& ConnectSPtr() const; diff --git a/tools/src/librlink/RtimerFd.hpp b/tools/src/librlink/RtimerFd.hpp index 7e56c9fa..e89af677 100644 --- a/tools/src/librlink/RtimerFd.hpp +++ b/tools/src/librlink/RtimerFd.hpp @@ -1,6 +1,6 @@ -// $Id: RtimerFd.hpp 983 2018-01-02 20:35:59Z mueller $ +// $Id: RtimerFd.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2013-2017 by Walter F.J. Mueller +// Copyright 2013-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.0.1 use =delete for noncopyable instead of boost // 2017-02-18 852 1.0 Initial version // 2013-01-11 473 0.1 First draft // --------------------------------------------------------------------------- @@ -28,17 +29,18 @@ #include -#include "boost/utility.hpp" - #include "librtools/Rtime.hpp" namespace Retro { - class RtimerFd : private boost::noncopyable { + class RtimerFd { public: RtimerFd(); virtual ~RtimerFd(); + + RtimerFd(const RtimerFd&) = delete; // noncopyable + RtimerFd& operator=(const RtimerFd&) = delete; // noncopyable void Open(clockid_t clkid=CLOCK_MONOTONIC); bool IsOpen() const; diff --git a/tools/src/librtcltools/RtclClassBase.hpp b/tools/src/librtcltools/RtclClassBase.hpp index 3e616093..d9240f03 100644 --- a/tools/src/librtcltools/RtclClassBase.hpp +++ b/tools/src/librtcltools/RtclClassBase.hpp @@ -1,6 +1,6 @@ -// $Id: RtclClassBase.hpp 1052 2018-09-30 08:10:52Z mueller $ +// $Id: RtclClassBase.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2011-2013 by Walter F.J. Mueller +// Copyright 2011-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.0.2 use =delete for noncopyable instead of boost // 2011-04-24 380 1.0.1 use boost::noncopyable (instead of private dcl's) // 2011-02-20 363 1.0 Initial version // 2011-02-11 360 0.1 First draft @@ -26,17 +27,18 @@ #ifndef included_Retro_RtclClassBase #define included_Retro_RtclClassBase 1 -#include "boost/utility.hpp" - #include "tcl.h" namespace Retro { - class RtclClassBase : private boost::noncopyable { + class RtclClassBase { public: explicit RtclClassBase(const std::string& type = std::string()); - virtual ~RtclClassBase(); + virtual ~RtclClassBase(); + + RtclClassBase(const RtclClassBase&) = delete; // noncopyable + RtclClassBase& operator=(const RtclClassBase&) = delete; // noncopyable const std::string& Type() const; Tcl_Command Token() const; diff --git a/tools/src/librtcltools/RtclCmdBase.hpp b/tools/src/librtcltools/RtclCmdBase.hpp index 02b7c35a..d8315f8e 100644 --- a/tools/src/librtcltools/RtclCmdBase.hpp +++ b/tools/src/librtcltools/RtclCmdBase.hpp @@ -1,4 +1,4 @@ -// $Id: RtclCmdBase.hpp 1083 2018-12-15 19:19:16Z mueller $ +// $Id: RtclCmdBase.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2013-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.1.4 use =delete for noncopyable instead of boost // 2018-12-15 1083 1.1.3 AddMeth(): use rval ref and move semantics // 2018-12-14 1081 1.1.2 use std::function instead of boost // 2017-04-02 865 1.1.1 add GetArgsDump() @@ -36,13 +37,11 @@ #include #include -#include "boost/utility.hpp" - #include "RtclArgs.hpp" namespace Retro { - class RtclCmdBase : private boost::noncopyable { + class RtclCmdBase { public: typedef std::function methfo_t; @@ -53,6 +52,9 @@ namespace Retro { RtclCmdBase(); virtual ~RtclCmdBase(); + RtclCmdBase(const RtclCmdBase&) = delete; // noncopyable + RtclCmdBase& operator=(const RtclCmdBase&) = delete; // noncopyable + int DispatchCmd(RtclArgs& args); void AddMeth(const std::string& name, methfo_t&& methfo); void DelMeth(const std::string& name); diff --git a/tools/src/librtcltools/RtclContext.hpp b/tools/src/librtcltools/RtclContext.hpp index 8d668821..a9cd213b 100644 --- a/tools/src/librtcltools/RtclContext.hpp +++ b/tools/src/librtcltools/RtclContext.hpp @@ -1,6 +1,6 @@ -// $Id: RtclContext.hpp 1066 2018-11-10 11:21:53Z mueller $ +// $Id: RtclContext.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2011-2017 by Walter F.J. Mueller +// Copyright 2011-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.0.5 use =delete for noncopyable instead of boost // 2017-02-04 866 1.0.4 rename fMapContext -> fContextMap // 2013-01-12 474 1.0.3 add FindProxy() method // 2011-04-24 380 1.0.2 use boost::noncopyable (instead of private dcl's) @@ -35,14 +36,12 @@ #include #include -#include "boost/utility.hpp" - #include "RtclClassBase.hpp" #include "RtclProxyBase.hpp" namespace Retro { - class RtclContext : private boost::noncopyable { + class RtclContext { public: typedef std::set cset_t; typedef std::set pset_t; @@ -50,6 +49,9 @@ namespace Retro { explicit RtclContext(Tcl_Interp* interp); virtual ~RtclContext(); + + RtclContext(const RtclContext&) = delete; // noncopyable + RtclContext& operator=(const RtclContext&) = delete; // noncopyable void RegisterClass(RtclClassBase* pobj); void UnRegisterClass(RtclClassBase* pobj); diff --git a/tools/src/librtcltools/RtclGetList.hpp b/tools/src/librtcltools/RtclGetList.hpp index 833e38ab..6703fde2 100644 --- a/tools/src/librtcltools/RtclGetList.hpp +++ b/tools/src/librtcltools/RtclGetList.hpp @@ -1,4 +1,4 @@ -// $Id: RtclGetList.hpp 1083 2018-12-15 19:19:16Z mueller $ +// $Id: RtclGetList.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2013-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.2.3 use =delete for noncopyable instead of boost // 2018-12-15 1083 1.2.2 Add(): use rval ref and move semantics // 2018-12-14 1081 1.2.1 use std::function instead of boost // 2018-12-01 1076 1.2 use unique_ptr @@ -35,19 +36,20 @@ #include #include -#include "boost/utility.hpp" - #include "RtclGet.hpp" #include "librtcltools/RtclArgs.hpp" namespace Retro { - class RtclGetList : private boost::noncopyable { + class RtclGetList { public: typedef std::unique_ptr get_uptr_t; RtclGetList(); virtual ~RtclGetList(); + + RtclGetList(const RtclGetList&) = delete; // noncopyable + RtclGetList& operator=(const RtclGetList&) = delete; // noncopyable void Add(const std::string& name, get_uptr_t&& upget); diff --git a/tools/src/librtcltools/RtclSetList.hpp b/tools/src/librtcltools/RtclSetList.hpp index 0f7618b7..63a37878 100644 --- a/tools/src/librtcltools/RtclSetList.hpp +++ b/tools/src/librtcltools/RtclSetList.hpp @@ -1,4 +1,4 @@ -// $Id: RtclSetList.hpp 1083 2018-12-15 19:19:16Z mueller $ +// $Id: RtclSetList.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2013-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.2.3 use =delete for noncopyable instead of boost // 2018-12-15 1083 1.2.2 Add(): use rval ref and move semantics // 2018-12-14 1081 1.2.1 use std::function instead of boost // 2018-12-01 1076 1.2 use unique_ptr @@ -35,20 +36,21 @@ #include #include -#include "boost/utility.hpp" - #include "RtclSet.hpp" #include "librtcltools/RtclArgs.hpp" namespace Retro { - class RtclSetList : private boost::noncopyable { + class RtclSetList { public: typedef std::unique_ptr set_uptr_t; RtclSetList(); virtual ~RtclSetList(); + RtclSetList(const RtclSetList&) = delete; // noncopyable + RtclSetList& operator=(const RtclSetList&) = delete; // noncopyable + void Add(const std::string& name, set_uptr_t&& upset); template diff --git a/tools/src/librtools/RlogFile.hpp b/tools/src/librtools/RlogFile.hpp index 7bc1ce6d..ba509f5b 100644 --- a/tools/src/librtools/RlogFile.hpp +++ b/tools/src/librtools/RlogFile.hpp @@ -1,6 +1,6 @@ -// $Id: RlogFile.hpp 983 2018-01-02 20:35:59Z mueller $ +// $Id: RlogFile.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2011-2015 by Walter F.J. Mueller +// Copyright 2011-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 2.2.1 use =delete for noncopyable instead of boost // 2015-01-08 631 2.2 Open(): now with RerrMsg and cout/cerr support // 2013-02-23 492 2.1 add Name(), keep log file name; add Dump() // 2013-02-22 491 2.0 add Write(),IsNew(), RlogMsg iface; use lockable @@ -32,7 +33,6 @@ #include #include -#include "boost/utility.hpp" #include "boost/thread/mutex.hpp" #include "RerrMsg.hpp" @@ -41,12 +41,15 @@ namespace Retro { class RlogMsg; // forw decl to avoid circular incl - class RlogFile : private boost::noncopyable { + class RlogFile { public: RlogFile(); explicit RlogFile(std::ostream* os, const std::string& name = ""); ~RlogFile(); + RlogFile(const RlogFile&) = delete; // noncopyable + RlogFile& operator=(const RlogFile&) = delete; // noncopyable + bool IsNew() const; bool Open(std::string name, RerrMsg& emsg); void Close(); diff --git a/tools/src/librtools/RlogFileCatalog.hpp b/tools/src/librtools/RlogFileCatalog.hpp index fa62e00a..991b2f64 100644 --- a/tools/src/librtools/RlogFileCatalog.hpp +++ b/tools/src/librtools/RlogFileCatalog.hpp @@ -1,4 +1,4 @@ -// $Id: RlogFileCatalog.hpp 1078 2018-12-08 14:19:03Z mueller $ +// $Id: RlogFileCatalog.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2011-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.0.2 use =delete for noncopyable instead of boost // 2018-12-07 1078 1.0.1 use std::shared_ptr instead of boost // 2013-02-22 491 1.0 Initial version // --------------------------------------------------------------------------- @@ -28,13 +29,11 @@ #include #include -#include "boost/utility.hpp" - #include "RlogFile.hpp" namespace Retro { - class RlogFileCatalog : private boost::noncopyable { + class RlogFileCatalog { public: static RlogFileCatalog& Obj(); @@ -46,7 +45,10 @@ namespace Retro { RlogFileCatalog(); ~RlogFileCatalog(); - protected: + RlogFileCatalog(const RlogFileCatalog&) = delete; // noncopy + RlogFileCatalog& operator=(const RlogFileCatalog&) = delete; // noncopy + + protected: typedef std::map> map_t; map_t fMap; //!< name->rlogfile map diff --git a/tools/src/librtools/RlogMsg.hpp b/tools/src/librtools/RlogMsg.hpp index 016a19ca..5b9c4886 100644 --- a/tools/src/librtools/RlogMsg.hpp +++ b/tools/src/librtools/RlogMsg.hpp @@ -1,6 +1,6 @@ -// $Id: RlogMsg.hpp 983 2018-01-02 20:35:59Z mueller $ +// $Id: RlogMsg.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2013- by Walter F.J. Mueller +// Copyright 2013-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.0.1 use =delete for noncopyable instead of boost // 2013-02-22 490 1.0 Initial version // --------------------------------------------------------------------------- @@ -26,18 +27,19 @@ #include -#include "boost/utility.hpp" - namespace Retro { class RlogFile; // forw decl to avoid circular incl - class RlogMsg : private boost::noncopyable { + class RlogMsg { public: explicit RlogMsg(char tag = 0); RlogMsg(RlogFile& lfile, char tag = 0); ~RlogMsg(); + RlogMsg(const RlogMsg&) = delete; // noncopyable + RlogMsg& operator=(const RlogMsg&) = delete; // noncopyable + void SetTag(char tag); void SetString(const std::string& str); diff --git a/tools/src/librw11/Rw11.hpp b/tools/src/librw11/Rw11.hpp index a6537bca..e0f71dbe 100644 --- a/tools/src/librw11/Rw11.hpp +++ b/tools/src/librw11/Rw11.hpp @@ -1,4 +1,4 @@ -// $Id: Rw11.hpp 1078 2018-12-08 14:19:03Z mueller $ +// $Id: Rw11.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2013-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.1.3 use =delete for noncopyable instead of boost // 2018-12-07 1078 1.1.2 use std::shared_ptr instead of boost // 2017-04-07 868 1.1.1 Dump(): add detail arg // 2014-12-29 624 1.1 adopt to Rlink V4 attn logic @@ -31,19 +32,20 @@ #include -#include "boost/utility.hpp" - #include "librlink/RlinkServer.hpp" namespace Retro { class Rw11Cpu; // forw decl to avoid circular incl - class Rw11 : private boost::noncopyable { + class Rw11 { public: Rw11(); virtual ~Rw11(); + + Rw11(const Rw11&) = delete; // noncopyable + Rw11& operator=(const Rw11&) = delete; // noncopyable void SetServer(const std::shared_ptr& spserv); const std::shared_ptr& ServerSPtr() const; diff --git a/tools/src/librw11/Rw11Cntl.hpp b/tools/src/librw11/Rw11Cntl.hpp index c1199fcd..d4603924 100644 --- a/tools/src/librw11/Rw11Cntl.hpp +++ b/tools/src/librw11/Rw11Cntl.hpp @@ -1,6 +1,6 @@ -// $Id: Rw11Cntl.hpp 983 2018-01-02 20:35:59Z mueller $ +// $Id: Rw11Cntl.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2013-2017 by Walter F.J. Mueller +// Copyright 2013-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.2.3 use =delete for noncopyable instead of boost // 2017-04-15 874 1.2.2 NUnit() now pure; add UnitBase() // 2017-04-02 865 1.2.1 Dump(): add detail arg // 2017-02-04 848 1.2 add ProbeFound(),ProbeDataInt,Rem() @@ -33,8 +34,6 @@ #include -#include "boost/utility.hpp" - #include "librtools/Rstats.hpp" #include "librlink/RlinkConnect.hpp" #include "librlink/RlinkServer.hpp" @@ -47,12 +46,15 @@ namespace Retro { class Rw11Unit; // forw decl to avoid circular incl - class Rw11Cntl : public Rbits, private boost::noncopyable { + class Rw11Cntl : public Rbits { public: explicit Rw11Cntl(const std::string& type); virtual ~Rw11Cntl(); + Rw11Cntl(const Rw11Cntl&) = delete; // noncopyable + Rw11Cntl& operator=(const Rw11Cntl&) = delete; // noncopyable + void SetCpu(Rw11Cpu* pcpu); Rw11Cpu& Cpu() const; Rw11& W11() const; diff --git a/tools/src/librw11/Rw11Cpu.hpp b/tools/src/librw11/Rw11Cpu.hpp index 5ddb4dd9..54f774df 100644 --- a/tools/src/librw11/Rw11Cpu.hpp +++ b/tools/src/librw11/Rw11Cpu.hpp @@ -1,4 +1,4 @@ -// $Id: Rw11Cpu.hpp 1078 2018-12-08 14:19:03Z mueller $ +// $Id: Rw11Cpu.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2013-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.2.13 use =delete for noncopyable instead of boost // 2018-12-07 1078 1.2.12 use std::shared_ptr instead of boost // 2018-09-23 1050 1.2.11 add HasPcnt() // 2017-04-07 868 1.2.10 Dump(): add detail arg @@ -47,7 +48,6 @@ #include #include -#include "boost/utility.hpp" #include "boost/thread/locks.hpp" #include "boost/thread/condition_variable.hpp" @@ -65,12 +65,15 @@ namespace Retro { class Rw11Cntl; // forw decl to avoid circular incl - class Rw11Cpu : public Rbits, private boost::noncopyable { + class Rw11Cpu : public Rbits { public: typedef std::map> cmap_t; explicit Rw11Cpu(const std::string& type); virtual ~Rw11Cpu(); + + Rw11Cpu(const Rw11Cpu&) = delete; // noncopyable + Rw11Cpu& operator=(const Rw11Cpu&) = delete; // noncopyable void Setup(Rw11* pw11); Rw11& W11() const; diff --git a/tools/src/librw11/Rw11Rdma.hpp b/tools/src/librw11/Rw11Rdma.hpp index 5655b4c8..50269cfd 100644 --- a/tools/src/librw11/Rw11Rdma.hpp +++ b/tools/src/librw11/Rw11Rdma.hpp @@ -1,4 +1,4 @@ -// $Id: Rw11Rdma.hpp 1083 2018-12-15 19:19:16Z mueller $ +// $Id: Rw11Rdma.hpp 1084 2018-12-16 12:23:53Z mueller $ // // Copyright 2015-2018 by Walter F.J. Mueller // @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.1.4 use =delete for noncopyable instead of boost // 2018-12-15 1083 1.1.3 for std::function setups: use rval ref and move // 2018-12-14 1081 1.1.2 use std::function instead of boost // 2017-04-02 865 1.1.1 Dump(): add detail arg @@ -31,8 +32,6 @@ #include -#include "boost/utility.hpp" - #include "librtools/Rstats.hpp" #include "librtools/RerrMsg.hpp" @@ -41,7 +40,7 @@ namespace Retro { - class Rw11Rdma : public Rbits, private boost::noncopyable { + class Rw11Rdma : public Rbits { public: typedef std::function +// Copyright 2013-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.1.4 use =delete for noncopyable instead of boost // 2017-04-15 875 1.1.3 add VirtBase(), IsAttached(), AttachUrl() // 2017-04-07 868 1.1.2 Dump(): add detail arg // 2015-05-13 680 1.1.1 add Enabled() @@ -33,8 +34,6 @@ #include -#include "boost/utility.hpp" - #include "librtools/Rstats.hpp" #include "librtools/RerrMsg.hpp" #include "librlink/RlinkServer.hpp" @@ -46,12 +45,15 @@ namespace Retro { class Rw11Virt; // forw decl to avoid circular incl - class Rw11Unit : public Rbits, private boost::noncopyable { + class Rw11Unit : public Rbits { public: Rw11Unit(Rw11Cntl* pcntl, size_t index); virtual ~Rw11Unit(); + Rw11Unit(const Rw11Unit&) = delete; // noncopyable + Rw11Unit& operator=(const Rw11Unit&) = delete; // noncopyable + size_t Index() const; std::string Name() const; diff --git a/tools/src/librw11/Rw11Virt.hpp b/tools/src/librw11/Rw11Virt.hpp index 65b469b3..af451286 100644 --- a/tools/src/librw11/Rw11Virt.hpp +++ b/tools/src/librw11/Rw11Virt.hpp @@ -1,6 +1,6 @@ -// $Id: Rw11Virt.hpp 1052 2018-09-30 08:10:52Z mueller $ +// $Id: Rw11Virt.hpp 1084 2018-12-16 12:23:53Z mueller $ // -// Copyright 2013-2017 by Walter F.J. Mueller +// Copyright 2013-2018 by Walter F.J. Mueller // // This program is free software; you may redistribute and/or modify it under // the terms of the GNU General Public License as published by the Free @@ -13,6 +13,7 @@ // // Revision History: // Date Rev Version Comment +// 2018-12-16 1084 1.1.3 use =delete for noncopyable instead of boost // 2017-04-15 875 1.1.2 add Url() const getter // 2017-04-07 868 1.1.1 Dump(): add detail arg // 2017-04-02 864 1.1 add fWProt,WProt() @@ -32,8 +33,6 @@ #include #include -#include "boost/utility.hpp" - #include "librtools/RparseUrl.hpp" #include "librtools/RerrMsg.hpp" #include "librtools/Rstats.hpp" @@ -41,11 +40,14 @@ namespace Retro { - class Rw11Virt : private boost::noncopyable { + class Rw11Virt { public: explicit Rw11Virt(Rw11Unit* punit); virtual ~Rw11Virt(); + Rw11Virt(const Rw11Virt&) = delete; // noncopyable + Rw11Virt& operator=(const Rw11Virt&) = delete; // noncopyable + Rw11Unit& Unit() const; Rw11Cntl& Cntl() const; Rw11Cpu& Cpu() const;