From facc5f6d288724fce12c9ab03810032249e2f037 Mon Sep 17 00:00:00 2001 From: kervala Date: Thu, 9 Aug 2018 14:27:42 +0200 Subject: [PATCH] Fixed: Warnings, throw(type) deprecated in C++11 and removed in C++17 --HG-- branch : develop --- code/nel/include/nel/misc/mem_stream.h | 2 +- code/nel/include/nel/net/module.h | 2 +- .../src/3d/driver/direct3d/driver_direct3d.h | 2 +- code/nel/src/misc/class_registry.cpp | 4 +-- .../3d/object_viewer/particle_workspace.cpp | 2 +- .../server/src/ai_service/ai_script_comp.cpp | 32 +++++++++---------- .../server/src/ai_service/ai_script_comp.h | 6 ++-- .../src/input_output_service/chat_manager.h | 2 +- 8 files changed, 26 insertions(+), 26 deletions(-) diff --git a/code/nel/include/nel/misc/mem_stream.h b/code/nel/include/nel/misc/mem_stream.h index a9e8aacfc..4222e1672 100644 --- a/code/nel/include/nel/misc/mem_stream.h +++ b/code/nel/include/nel/misc/mem_stream.h @@ -210,7 +210,7 @@ public: * \return the new offset regarding from the origin. * \see ESeekNotSupported SeekOrigin seek */ - virtual sint32 getPos () const throw(EStream) + virtual sint32 getPos () const { return sint32(_Buffer.Pos); } diff --git a/code/nel/include/nel/net/module.h b/code/nel/include/nel/net/module.h index 0b5b158d2..05cd48fed 100644 --- a/code/nel/include/nel/net/module.h +++ b/code/nel/include/nel/net/module.h @@ -780,7 +780,7 @@ namespace NLNET bool initModule(const TParsedCommandLine &initInfo); void plugModule(IModuleSocket *moduleSocket); - void unplugModule(IModuleSocket *moduleSocket) throw (EModuleNotPluggedHere); + void unplugModule(IModuleSocket *moduleSocket); void getPluggedSocketList(std::vector &resultList); void invokeModuleOperation(IModuleProxy *destModule, const NLNET::CMessage &opMsg, NLNET::CMessage &resultMsg); void _onModuleUp(IModuleProxy *removedProxy); diff --git a/code/nel/src/3d/driver/direct3d/driver_direct3d.h b/code/nel/src/3d/driver/direct3d/driver_direct3d.h index 6621ab6cb..51c21bbc9 100644 --- a/code/nel/src/3d/driver/direct3d/driver_direct3d.h +++ b/code/nel/src/3d/driver/direct3d/driver_direct3d.h @@ -849,7 +849,7 @@ public: // Mode initialisation, requests virtual bool init (uintptr_t windowIcon = 0, emptyProc exitFunc = 0); - virtual bool setDisplay(nlWindow wnd, const GfxMode& mode, bool show, bool resizeable + virtual bool setDisplay(nlWindow wnd, const GfxMode& mode, bool show, bool resizeable); virtual bool release(); virtual bool setMode(const GfxMode& mode); virtual bool getModes(std::vector &modes); diff --git a/code/nel/src/misc/class_registry.cpp b/code/nel/src/misc/class_registry.cpp index 91c603c90..c703e45d0 100644 --- a/code/nel/src/misc/class_registry.cpp +++ b/code/nel/src/misc/class_registry.cpp @@ -49,7 +49,7 @@ void CClassRegistry::release() } // ====================================================================================================== -IClassable *CClassRegistry::create(const string &className) throw(ERegistry) +IClassable *CClassRegistry::create(const string &className) { init(); @@ -72,7 +72,7 @@ IClassable *CClassRegistry::create(const string &className) throw(ERegistry) } // ====================================================================================================== -void CClassRegistry::registerClass(const string &className, IClassable* (*creator)(), const string &typeidCheck) throw(ERegistry) +void CClassRegistry::registerClass(const string &className, IClassable* (*creator)(), const string &typeidCheck) { init(); diff --git a/code/nel/tools/3d/object_viewer/particle_workspace.cpp b/code/nel/tools/3d/object_viewer/particle_workspace.cpp index 43be30812..1a289d2b0 100644 --- a/code/nel/tools/3d/object_viewer/particle_workspace.cpp +++ b/code/nel/tools/3d/object_viewer/particle_workspace.cpp @@ -357,7 +357,7 @@ void CParticleWorkspace::setName(const std::string &name) //*********************************************************************************************** -CParticleWorkspace::CNode *CParticleWorkspace::addNode(const std::string &filenameWithFullPath) throw( NLMISC::EStream) +CParticleWorkspace::CNode *CParticleWorkspace::addNode(const std::string &filenameWithFullPath) { nlassert(_OV); // Check that file is not already inserted diff --git a/code/ryzom/server/src/ai_service/ai_script_comp.cpp b/code/ryzom/server/src/ai_service/ai_script_comp.cpp index d076e6832..69c4c9bab 100644 --- a/code/ryzom/server/src/ai_service/ai_script_comp.cpp +++ b/code/ryzom/server/src/ai_service/ai_script_comp.cpp @@ -83,7 +83,7 @@ std::string CFightSelectFilter::toString() const -CFightScriptComp *CFightSelectFilterReader::create (const std::string &inStr) throw (ReadFightActionException) +CFightScriptComp *CFightSelectFilterReader::create (const std::string &inStr) { std::vector params; explodeSubStrings(inStr, params, -1); @@ -151,7 +151,7 @@ public: CFightOnceReader() {} virtual ~CFightOnceReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector params; explodeSubStrings(inStr, params, -1); @@ -229,7 +229,7 @@ public: CFightTimedFilterReader() {} virtual ~CFightTimedFilterReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector params; explodeSubStrings(inStr, params, -1); @@ -302,7 +302,7 @@ public: CFightHPLessFilterReader() {} virtual ~CFightHPLessFilterReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector params; explodeSubStrings(inStr, params, -1); @@ -372,7 +372,7 @@ public: CFightHPMoreFilterReader() {} virtual ~CFightHPMoreFilterReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector params; explodeSubStrings(inStr, params, -1); @@ -443,7 +443,7 @@ public: CFightRandomFilterReader() {} virtual ~CFightRandomFilterReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector params; explodeSubStrings(inStr, params, -1); @@ -523,7 +523,7 @@ public: CFightSendActionReader() {} virtual ~CFightSendActionReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector strings; explodeSubStrings(inStr, strings, -1); @@ -588,7 +588,7 @@ public: CFightSendSelfActionReader() {} virtual ~CFightSendSelfActionReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector strings; explodeSubStrings(inStr, strings, -1); @@ -647,7 +647,7 @@ public: CFightAggroBlockReader() {} virtual ~CFightAggroBlockReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector strings; explodeSubStrings(inStr, strings, -1); @@ -705,7 +705,7 @@ public: CFightAggroChangeReader() {} virtual ~CFightAggroChangeReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { return new CFightAggroChange(); } @@ -751,7 +751,7 @@ public: CFightDamageCoefReader() {} virtual ~CFightDamageCoefReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector strings; explodeSubStrings(inStr, strings, -1); @@ -818,7 +818,7 @@ public: CFightGroupDamageCoefReader() {} virtual ~CFightGroupDamageCoefReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector strings; explodeSubStrings(inStr, strings, -1); @@ -871,7 +871,7 @@ public: CFightDamageSpeedCoefReader() {} virtual ~CFightDamageSpeedCoefReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector strings; explodeSubStrings(inStr, strings, -1); @@ -933,7 +933,7 @@ public: CFightSetRandomTargetReader() {} virtual ~CFightSetRandomTargetReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector strings; explodeSubStrings(inStr, strings, -1); @@ -1003,7 +1003,7 @@ public: CFightMultReader() {} virtual ~CFightMultReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) + CFightScriptComp *create (const std::string &inStr) { vector params; explodeSubStrings(inStr, params, -1); @@ -1075,7 +1075,7 @@ CFightScriptCompReader *CFightScriptCompReader::getScriptReader (const string &s return &(*(it->second)); } -CFightScriptComp *CFightScriptCompReader::createScriptComp (const string &str) throw (ReadFightActionException) +CFightScriptComp *CFightScriptCompReader::createScriptComp (const string &str) { string scriptCompName; { diff --git a/code/ryzom/server/src/ai_service/ai_script_comp.h b/code/ryzom/server/src/ai_service/ai_script_comp.h index 0b02cc722..a35253d66 100644 --- a/code/ryzom/server/src/ai_service/ai_script_comp.h +++ b/code/ryzom/server/src/ai_service/ai_script_comp.h @@ -51,12 +51,12 @@ public: {} virtual ~CFightScriptCompReader() {} - virtual CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException) = 0; + virtual CFightScriptComp *create (const std::string &inStr) = 0; virtual std::string getName () const =0; static CFightScriptCompReader *getScriptReader (const std::string &str); - static CFightScriptComp *createScriptComp (const std::string &str) throw (ReadFightActionException); + static CFightScriptComp *createScriptComp (const std::string &str) protected: private: }; @@ -116,7 +116,7 @@ public: CFightSelectFilterReader() {} virtual ~CFightSelectFilterReader() {} - CFightScriptComp *create (const std::string &inStr) throw (ReadFightActionException); + CFightScriptComp *create (const std::string &inStr) std::string getName () const { return std::string("SELECT"); diff --git a/code/ryzom/server/src/input_output_service/chat_manager.h b/code/ryzom/server/src/input_output_service/chat_manager.h index 658a72d81..a64b68d52 100644 --- a/code/ryzom/server/src/input_output_service/chat_manager.h +++ b/code/ryzom/server/src/input_output_service/chat_manager.h @@ -101,7 +101,7 @@ public : * Get the client infos * \param id is the client character id */ - CChatClient& getClient( const TDataSetRow& id ); //throw (EChatClient); + CChatClient& getClient( const TDataSetRow& id ); /** * Return a reference on the static database