From af8ab09baba1d099a6ad30fc5f17b0fd6393f8ec Mon Sep 17 00:00:00 2001 From: eap Date: Mon, 15 Mar 2021 18:06:53 +0300 Subject: [PATCH] Fix som ewarnings --- src/SMDS/SMDS_VolumeTool.hxx | 2 +- src/SMESHUtils/SMESH_OctreeNode.hxx | 2 +- src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.h | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/SMDS/SMDS_VolumeTool.hxx b/src/SMDS/SMDS_VolumeTool.hxx index b22a99bbf..9f566325d 100644 --- a/src/SMDS/SMDS_VolumeTool.hxx +++ b/src/SMDS/SMDS_VolumeTool.hxx @@ -97,7 +97,7 @@ class SMDS_EXPORT SMDS_VolumeTool const SMDS_MeshNode** GetNodes() const { return (const SMDS_MeshNode**) &myVolumeNodes[0]; } // Return array of volume nodes - int NbNodes() const { return myVolumeNodes.size(); } + int NbNodes() const { return (int) myVolumeNodes.size(); } // Return array of volume nodes double GetSize() const; diff --git a/src/SMESHUtils/SMESH_OctreeNode.hxx b/src/SMESHUtils/SMESH_OctreeNode.hxx index 670843c9e..880f373f5 100644 --- a/src/SMESHUtils/SMESH_OctreeNode.hxx +++ b/src/SMESHUtils/SMESH_OctreeNode.hxx @@ -108,7 +108,7 @@ class SMESHUtils_EXPORT SMESH_OctreeNode : public SMESH_Octree /*! * \brief Return nb nodes in a tree */ - int NbNodes() const { return myNodes.size(); } + size_t NbNodes() const { return myNodes.size(); } protected: diff --git a/src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.h b/src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.h index 44fa5ef94..a35610402 100644 --- a/src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.h +++ b/src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.h @@ -68,7 +68,7 @@ public: void SetObjects(SMESH::string_array_var& objEntries); template - typename TInterface::_var_type GetObject(unsigned i=0) const { + typename TInterface::_var_type GetObject(size_t i=0) const { if ( IsObjectSelected(i) ) return TInterface::_narrow(myObjects[i]); return TInterface::_nil(); } @@ -77,7 +77,7 @@ public: QString GetValue() const { return myParamValue; } - bool IsObjectSelected(unsigned i=0) const + bool IsObjectSelected(size_t i=0) const { return i < myObjects.size() && !CORBA::is_nil(myObjects[i]); } /*! -- 2.39.2