From 518354b4be55f00f9c90938f411757bfaacace55 Mon Sep 17 00:00:00 2001 From: SALOME Date: Wed, 26 Aug 2020 10:50:37 +0300 Subject: [PATCH] fight warnings c++17, fix minor warnings. Build HYBRIDPLUGIN finished --- src/HYBRIDPlugin/HYBRIDPlugin_HYBRID.cxx | 14 +++++++------- src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis.cxx | 2 +- src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.cxx | 4 ++-- src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.hxx | 12 ++++++------ src/HYBRIDPlugin/HYBRIDPlugin_i.cxx | 2 +- src/HYBRIDPlugin/MG_HYBRID_API.cxx | 2 +- src/HYBRIDPlugin/MG_HYBRID_API.hxx | 2 +- 7 files changed, 19 insertions(+), 19 deletions(-) diff --git a/src/HYBRIDPlugin/HYBRIDPlugin_HYBRID.cxx b/src/HYBRIDPlugin/HYBRIDPlugin_HYBRID.cxx index 07dec79..d3fe429 100644 --- a/src/HYBRIDPlugin/HYBRIDPlugin_HYBRID.cxx +++ b/src/HYBRIDPlugin/HYBRIDPlugin_HYBRID.cxx @@ -190,7 +190,7 @@ TopoDS_Shape HYBRIDPlugin_HYBRID::entryToShape(std::string entry) static void addElemInMeshGroup(SMESH_Mesh* theMesh, const SMDS_MeshElement* anElem, std::string& groupName, - std::set& groupsToRemove) + std::set& /*groupsToRemove*/) { if ( !anElem ) return; // issue 0021776 @@ -329,7 +329,7 @@ static bool readGMFFile(MG_HYBRID_API* MGOutput, SMESH_MesherHelper* theHelper, std::vector & theNodeByHybridId, std::vector & theFaceByHybridId, - std::map & theNodeToHybridIdMap, + std::map & /*theNodeToHybridIdMap*/, std::vector & aNodeGroupByHybridId, std::vector & anEdgeGroupByHybridId, std::vector & aFaceGroupByHybridId, @@ -2298,9 +2298,9 @@ namespace */ void ProcessEvent(const int event, const int eventType, - SMESH_subMesh* subMesh, + SMESH_subMesh* /*subMesh*/, SMESH_subMeshEventListenerData* data, - const SMESH_Hypothesis* hyp) + const SMESH_Hypothesis* /*hyp*/) { if ( SMESH_subMesh::SUBMESH_LOADED == event && SMESH_subMesh::COMPUTE_EVENT == eventType && @@ -2339,11 +2339,11 @@ namespace /*! * \brief Treat events of the subMesh */ - void ProcessEvent(const int event, + void ProcessEvent(const int /*event*/, const int eventType, SMESH_subMesh* subMesh, - SMESH_subMeshEventListenerData* data, - const SMESH_Hypothesis* hyp) + SMESH_subMeshEventListenerData* /*data*/, + const SMESH_Hypothesis* /*hyp*/) { if (SMESH_subMesh::ALGO_EVENT == eventType && !subMesh->GetAlgo() ) diff --git a/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis.cxx b/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis.cxx index 57c0150..22de54e 100644 --- a/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis.cxx +++ b/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis.cxx @@ -180,7 +180,7 @@ void HYBRIDPlugin_Hypothesis::SetLayersOnAllWrap(bool toMesh) //function : GetLayersOnAllWrap //======================================================================= -bool HYBRIDPlugin_Hypothesis::GetLayersOnAllWrap(bool checkFreeOption) const +bool HYBRIDPlugin_Hypothesis::GetLayersOnAllWrap(bool /*checkFreeOption*/) const { return myLayersOnAllWrap; } diff --git a/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.cxx b/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.cxx index c5701a0..3274d1a 100644 --- a/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.cxx +++ b/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.cxx @@ -1541,7 +1541,7 @@ bool HYBRIDPlugin_Hypothesis_i::SetEnforcedMesh(SMESH::SMESH_IDSource_ptr theSou /*! * \brief OBSOLETE FUNCTION - Adds enforced elements of type elementType using another mesh/sub-mesh/mesh group theSource and a size. The elements will be grouped in theGroupName. */ -bool HYBRIDPlugin_Hypothesis_i::SetEnforcedMeshSizeWithGroup(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType theType, double theSize, const char* theGroupName) +bool HYBRIDPlugin_Hypothesis_i::SetEnforcedMeshSizeWithGroup(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType theType, double /*theSize*/, const char* theGroupName) { // #if HYBRID_VERSION >= 42 return p_SetEnforcedMesh(theSource, theType, "", theGroupName); @@ -1558,7 +1558,7 @@ bool HYBRIDPlugin_Hypothesis_i::SetEnforcedMeshSizeWithGroup(SMESH::SMESH_IDSour /*! * \brief OBSOLETE FUNCTION - Adds enforced elements of type elementType using another mesh/sub-mesh/mesh group theSource and a size. */ -bool HYBRIDPlugin_Hypothesis_i::SetEnforcedMeshSize(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType theType, double theSize) +bool HYBRIDPlugin_Hypothesis_i::SetEnforcedMeshSize(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType theType, double /*theSize*/) { // #if HYBRID_VERSION >= 42 return p_SetEnforcedMesh(theSource, theType); diff --git a/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.hxx b/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.hxx index f87e9bc..370d173 100644 --- a/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.hxx +++ b/src/HYBRIDPlugin/HYBRIDPlugin_Hypothesis_i.hxx @@ -248,8 +248,8 @@ class HYBRIDPLUGIN_EXPORT HYBRIDPlugin_Hypothesis_i: bool SetEnforcedMeshWithGroup(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType elementType, const char* theGroupName) ; /* OBSOLETE FUNCTIONS */ - bool SetEnforcedMeshSize(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType elementType, double size) ; - bool SetEnforcedMeshSizeWithGroup(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType elementType, double size, const char* theGroupName) ; + bool SetEnforcedMeshSize(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType elementType, double /*size*/) ; + bool SetEnforcedMeshSizeWithGroup(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType elementType, double /*size*/, const char* theGroupName) ; /* OBSOLETE FUNCTIONS */ HYBRIDPlugin::HYBRIDEnforcedMeshList* GetEnforcedMeshes(); @@ -262,10 +262,10 @@ class HYBRIDPLUGIN_EXPORT HYBRIDPlugin_Hypothesis_i: CORBA::Boolean IsDimSupported( SMESH::Dimension type ); // Methods for copying mesh definition to other geometry - virtual bool getObjectsDependOn( std::vector< std::string > & entryArray, - std::vector< int > & subIDArray ) const { return false; } - virtual bool setObjectsDependOn( std::vector< std::string > & entryArray, - std::vector< int > & subIDArray ) { return true; } + virtual bool getObjectsDependOn( std::vector< std::string > & /*entryArray*/, + std::vector< int > & /*subIDArray*/ ) const { return false; } + virtual bool setObjectsDependOn( std::vector< std::string > & /*entryArray*/, + std::vector< int > & /*subIDArray*/ ) { return true; } }; #endif diff --git a/src/HYBRIDPlugin/HYBRIDPlugin_i.cxx b/src/HYBRIDPlugin/HYBRIDPlugin_i.cxx index b54cf6e..c083361 100644 --- a/src/HYBRIDPlugin/HYBRIDPlugin_i.cxx +++ b/src/HYBRIDPlugin/HYBRIDPlugin_i.cxx @@ -58,7 +58,7 @@ extern "C" // Hypothesis else if (strcmp(aHypName, "HYBRID_Parameters") == 0) aCreator = new HYBRIDPlugin_Creator_i; - else ; + /*else ;*/ return aCreator; } diff --git a/src/HYBRIDPlugin/MG_HYBRID_API.cxx b/src/HYBRIDPlugin/MG_HYBRID_API.cxx index 248283f..c5d360b 100644 --- a/src/HYBRIDPlugin/MG_HYBRID_API.cxx +++ b/src/HYBRIDPlugin/MG_HYBRID_API.cxx @@ -910,7 +910,7 @@ void MG_HYBRID_API::GmfGotoKwd( int iMesh, GmfKwdCod what ) */ //================================================================================ -void MG_HYBRID_API::GmfGetLin( int iMesh, GmfKwdCod what, int* nbNodes, int* faceInd, int* ori, int* domain, int dummy ) +void MG_HYBRID_API::GmfGetLin( int iMesh, GmfKwdCod what, int* nbNodes, int* faceInd, int* ori, int* domain, int /*dummy*/ ) { if ( _useLib ) { #ifdef USE_MG_LIBS diff --git a/src/HYBRIDPlugin/MG_HYBRID_API.hxx b/src/HYBRIDPlugin/MG_HYBRID_API.hxx index 8ae635f..2d9b132 100644 --- a/src/HYBRIDPlugin/MG_HYBRID_API.hxx +++ b/src/HYBRIDPlugin/MG_HYBRID_API.hxx @@ -59,7 +59,7 @@ public: int GmfOpenMesh(const char* theFile, int rdOrWr, int * ver, int * dim); int GmfStatKwd( int iMesh, GmfKwdCod what ); void GmfGotoKwd( int iMesh, GmfKwdCod what ); - void GmfGetLin( int iMesh, GmfKwdCod what, int* nbNodes, int* faceInd, int* ori, int* domain, int dummy ); + void GmfGetLin( int iMesh, GmfKwdCod what, int* nbNodes, int* faceInd, int* ori, int* domain, int /*dummy*/ ); void GmfGetLin(int iMesh, GmfKwdCod what, float* x, float* y, float *z, int* domain ); void GmfGetLin(int iMesh, GmfKwdCod what, double* x, double* y, double *z, int* domain ); void GmfGetLin(int iMesh, GmfKwdCod what, int* node ); -- 2.39.2