From f052cd2f219ce060719d1f355614e4eee37733e1 Mon Sep 17 00:00:00 2001 From: SALOME Date: Fri, 21 Aug 2020 08:03:19 +0300 Subject: [PATCH] fight warnings c++17 error throw(). Build GEOM finished. Fix other warnings --- src/Basics/Basics_DirUtils.cxx | 14 +-- src/Container/Container_i.cxx | 4 +- src/Container/SALOME_ContainerManager.cxx | 68 ++++------- src/Container/TestSalome_file.cxx | 2 +- src/DF/DF_Label.cxx | 2 +- src/DSC/DSC_User/DSC_Exception.hxx | 2 +- .../DSC_User/Datastream/Calcium/Calcium.hxx | 6 +- .../Datastream/Calcium/CalciumCInterface.hxx | 22 ++-- .../Calcium/CalciumCouplingPolicy.cxx | 8 +- .../Calcium/CalciumCouplingPolicy.hxx | 12 +- .../Calcium/CalciumCxxInterface.cxx | 2 +- .../Calcium/CalciumCxxInterface.hxx | 14 +-- .../Calcium/CalciumGenericProvidesPort.hxx | 6 +- .../Calcium/CalciumGenericUsesPort.hxx | 2 +- .../Calcium/calcium_destructors_port_uses.cxx | 16 +-- .../Calcium/calcium_provides_port.hxx | 2 +- .../Datastream/Calcium/calcium_uses_port.hxx | 2 +- .../Datastream/CorbaTypeManipulator.hxx | 6 +- src/DSC/DSC_User/Datastream/DisplayPair.hxx | 2 +- src/DSC/DSC_User/Datastream/GenericPort.hxx | 2 +- .../DSC_User/Datastream/GenericUsesPort.hxx | 10 +- src/DSC/DSC_User/Datastream/fake.cc | 2 +- src/DSC/DSC_User/Superv_Component_i.cxx | 21 ++-- src/DSC/DSC_User/Superv_Component_i.hxx | 29 +++-- src/DSC/DSC_User/provides_port.hxx | 4 +- src/GenericObj/SALOME_GenericObj_i.cc | 2 +- src/HDFPersist/HDFconvert.cc | 2 +- src/HDFPersist/HDFgroup.cc | 2 +- .../SALOMEDS_DriverDefaultImpl.cxx | 112 +++++++++--------- .../SALOMEDS_DriverDefaultImpl.hxx | 64 +++++----- src/Launcher/SALOME_ExternalServerHandler.cxx | 2 +- .../SALOME_ExternalServerLauncher.cxx | 2 +- src/Launcher/SALOME_Launcher_Parser.cxx | 4 +- .../SALOME_ModuleCatalog_Acomponent_impl.cxx | 2 +- .../SALOME_ModuleCatalog_impl.cxx | 2 +- src/NamingService/SALOME_NamingService.cxx | 12 +- src/SALOMEDS/SALOMEDS.hxx | 2 +- .../SALOMEDSImpl_AttributeParameter.cxx | 4 +- ...ALOMEDSImpl_AttributeSequenceOfInteger.cxx | 6 +- .../SALOMEDSImpl_AttributeSequenceOfReal.cxx | 6 +- .../SALOMEDSImpl_AttributeStudyProperties.cxx | 14 +-- .../SALOMEDSImpl_AttributeTableOfInteger.cxx | 18 +-- .../SALOMEDSImpl_AttributeTableOfReal.cxx | 8 +- .../SALOMEDSImpl_AttributeTableOfString.cxx | 22 ++-- src/SALOMEDSImpl/SALOMEDSImpl_Callback.hxx | 12 +- .../SALOMEDSImpl_StudyBuilder.cxx | 4 +- src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx | 10 +- .../SALOMESDS_PickelizedPyObjRdOnlyServer.cxx | 2 +- .../SALOMESDS_PickelizedPyObjServer.cxx | 4 +- src/SALOMESDS/SALOMESDS_RefCountServ.cxx | 2 +- src/SALOMESDS/SALOMESDS_Sha1Keeper.cxx | 2 +- src/Utils/Test/UtilsTest.cxx | 2 +- 52 files changed, 284 insertions(+), 300 deletions(-) diff --git a/src/Basics/Basics_DirUtils.cxx b/src/Basics/Basics_DirUtils.cxx index dee7639da..9fc6eb6f0 100644 --- a/src/Basics/Basics_DirUtils.cxx +++ b/src/Basics/Basics_DirUtils.cxx @@ -55,12 +55,12 @@ namespace Kernel_Utils { std::string tmp_str = file_path; auto pos = file_path.rfind( _separator_ ); - if ( pos >= 0 ) - tmp_str = pos < (int)file_path.size()-1 ? file_path.substr( pos+1 ) : ""; + if ( pos >= 0 ) // TODO: always true + tmp_str = pos < file_path.size()-1 ? file_path.substr( pos+1 ) : ""; pos = tmp_str.rfind( _extension_ ); - if( !with_extension && pos >= 0 ) - tmp_str = pos < (int)tmp_str.size()-1 ? tmp_str.substr( 0, pos ) : ""; + if( !with_extension && pos >= 0 ) // TODO: always true + tmp_str = pos < tmp_str.size()-1 ? tmp_str.substr( 0, pos ) : ""; return tmp_str; } @@ -68,8 +68,8 @@ namespace Kernel_Utils std::string GetDirName( const std::string& file_path ) { auto pos = file_path.rfind( _separator_ ); - if ( pos >= 0 ) - return pos < (int)file_path.size()-1 ? file_path.substr(0, pos ) : ""; + if ( pos >= 0 ) // TODO: always true + return pos < file_path.size()-1 ? file_path.substr(0, pos ) : ""; return std::string("."); } @@ -191,7 +191,7 @@ namespace Kernel_Utils { std::string tmp_str = name; auto pos = tmp_str.rfind( _extension_ ); - if( pos < 0 ) + if( pos < 0 ) // TODO: always true return tmp_str.append( _extension_ ); return tmp_str; } diff --git a/src/Container/Container_i.cxx b/src/Container/Container_i.cxx index 12369b96e..b8766c00e 100644 --- a/src/Container/Container_i.cxx +++ b/src/Container/Container_i.cxx @@ -1387,9 +1387,9 @@ void SetCpuUsed() ; void CallCancelThread() ; #ifndef WIN32 -void SigIntHandler(int what , +void SigIntHandler(int /*what*/ , siginfo_t * siginfo , - void * toto ) + void * /*toto*/ ) { //PAL9042 JR : during the execution of a Signal Handler (and of methods called through Signal Handlers) // use of streams (and so on) should never be used because : diff --git a/src/Container/SALOME_ContainerManager.cxx b/src/Container/SALOME_ContainerManager.cxx index 665804255..310551486 100644 --- a/src/Container/SALOME_ContainerManager.cxx +++ b/src/Container/SALOME_ContainerManager.cxx @@ -2010,10 +2010,9 @@ SALOME_ContainerManager::LaunchPaCONodeContainer(const std::string& command, #else Engines::Container_ptr -SALOME_ContainerManager::StartPaCOPPContainer(const Engines::ContainerParameters& params, - std::string resource_selected) +SALOME_ContainerManager::StartPaCOPPContainer(const Engines::ContainerParameters& /*params*/, + std::string /*resource_selected*/) { - SALOME_UNUSED(params); Engines::Container_ptr ret = Engines::Container::_nil(); INFOS("[StarPaCOPPContainer] is disabled !"); INFOS("[StarPaCOPPContainer] recompile SALOME Kernel to enable PaCO++ parallel extension"); @@ -2021,65 +2020,46 @@ SALOME_ContainerManager::StartPaCOPPContainer(const Engines::ContainerParameters } std::string -SALOME_ContainerManager::BuildCommandToLaunchPaCOProxyContainer(const Engines::ContainerParameters& params, - std::string machine_file_name, - std::string & proxy_hostname) +SALOME_ContainerManager::BuildCommandToLaunchPaCOProxyContainer(const Engines::ContainerParameters& /*params*/, + std::string /*machine_file_name*/, + std::string & /*proxy_hostname*/) { - SALOME_UNUSED(params); - SALOME_UNUSED(proxy_hostname); return ""; } std::string -SALOME_ContainerManager::BuildCommandToLaunchPaCONodeContainer(const Engines::ContainerParameters& params, - const std::string & machine_file_name, - SALOME_ContainerManager::actual_launch_machine_t & vect_machine, - const std::string & proxy_hostname) +SALOME_ContainerManager::BuildCommandToLaunchPaCONodeContainer(const Engines::ContainerParameters& /*params*/, + const std::string & /*machine_file_name*/, + SALOME_ContainerManager::actual_launch_machine_t & /*vect_machine*/, + const std::string & /*proxy_hostname*/) { - SALOME_UNUSED(params); - SALOME_UNUSED(machine_file_name); - SALOME_UNUSED(vect_machine); - SALOME_UNUSED(proxy_hostname); return ""; } void -SALOME_ContainerManager::LogConfiguration(const std::string & log_type, - const std::string & exe_type, - const std::string & container_name, - const std::string & hostname, - std::string & begin, - std::string & end) +SALOME_ContainerManager::LogConfiguration(const std::string & /*log_type*/, + const std::string & /*exe_type*/, + const std::string & /*container_name*/, + const std::string & /*hostname*/, + std::string & /*begin*/, + std::string & /*end*/) { - SALOME_UNUSED(log_type); - SALOME_UNUSED(exe_type); - SALOME_UNUSED(container_name); - SALOME_UNUSED(hostname); - SALOME_UNUSED(begin); - SALOME_UNUSED(end); } CORBA::Object_ptr -SALOME_ContainerManager::LaunchPaCOProxyContainer(const std::string& command, - const Engines::ContainerParameters& params, - const std::string& hostname) +SALOME_ContainerManager::LaunchPaCOProxyContainer(const std::string& /*command*/, + const Engines::ContainerParameters& /*params*/, + const std::string& /*hostname*/) { - SALOME_UNUSED(command); - SALOME_UNUSED(params); - SALOME_UNUSED(hostname); CORBA::Object_ptr ret = CORBA::Object::_nil(); return ret; } bool -SALOME_ContainerManager::LaunchPaCONodeContainer(const std::string& command, - const Engines::ContainerParameters& params, - const std::string& name, - SALOME_ContainerManager::actual_launch_machine_t & vect_machine) -{ - SALOME_UNUSED(command); - SALOME_UNUSED(params); - SALOME_UNUSED(name); - SALOME_UNUSED(vect_machine); - return false; +SALOME_ContainerManager::LaunchPaCONodeContainer(const std::string& /*command*/, + const Engines::ContainerParameters& /*params*/, + const std::string& /*name*/, + SALOME_ContainerManager::actual_launch_machine_t & /*vect_machine*/) +{ + return false; } #endif diff --git a/src/Container/TestSalome_file.cxx b/src/Container/TestSalome_file.cxx index 36095892a..2195c489f 100644 --- a/src/Container/TestSalome_file.cxx +++ b/src/Container/TestSalome_file.cxx @@ -73,7 +73,7 @@ int main (int argc, char * argv[]) std::cerr << "+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++" << std::endl; std::cerr << "Test of getFilesInfos()" << std::endl; all_infos = file.getFilesInfos(); - for (int i = 0; i < all_infos->length(); i++) + for (int i = 0; i < (int)all_infos->length(); i++) { print_infos(&((*all_infos)[i])); } diff --git a/src/DF/DF_Label.cxx b/src/DF/DF_Label.cxx index 7bcc0468b..6b4761bda 100644 --- a/src/DF/DF_Label.cxx +++ b/src/DF/DF_Label.cxx @@ -247,7 +247,7 @@ std::vector DF_Label::GetAttributes() const sort(sorted.begin(), sorted.end()); size_t len = sorted.size(); - for(int i = 0; i_attributes[sorted[i]]); return attributes; diff --git a/src/DSC/DSC_User/DSC_Exception.hxx b/src/DSC/DSC_User/DSC_Exception.hxx index 15a55778f..c44cf2560 100644 --- a/src/DSC/DSC_User/DSC_Exception.hxx +++ b/src/DSC/DSC_User/DSC_Exception.hxx @@ -176,6 +176,6 @@ protected: //Sert à eviter le problème d'identification RTTI des exceptions //Crée un unique typeInfo pour tous les bibliothèques composants SALOME //dans un fichier cxx -#define DSC_EXCEPTION_CXX(NameSpace,Derived) NameSpace::Derived::~Derived(void) {}; +#define DSC_EXCEPTION_CXX(NameSpace,Derived) NameSpace::Derived::~Derived(void) {} #endif /* DSC_EXCEPTION_HXX */ diff --git a/src/DSC/DSC_User/Datastream/Calcium/Calcium.hxx b/src/DSC/DSC_User/Datastream/Calcium/Calcium.hxx index 93551353b..f0e4f98fb 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/Calcium.hxx +++ b/src/DSC/DSC_User/Datastream/Calcium/Calcium.hxx @@ -29,9 +29,9 @@ class PySupervCompo:public Superv_Component_i const char *interfaceName, bool notif = false); virtual ~PySupervCompo(); - CORBA::Boolean init_service(const char * service_name){return true;}; - CORBA::Boolean init_service_with_multiple(const char* service_name, - const Engines::Superv_Component::seq_multiple_param & params) + CORBA::Boolean init_service(const char * /*service_name*/){return true;}; + CORBA::Boolean init_service_with_multiple(const char* /*service_name*/, + const Engines::Superv_Component::seq_multiple_param & /*params*/) { return true; } diff --git a/src/DSC/DSC_User/Datastream/Calcium/CalciumCInterface.hxx b/src/DSC/DSC_User/Datastream/Calcium/CalciumCInterface.hxx index 83c05e26a..f934245db 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/CalciumCInterface.hxx +++ b/src/DSC/DSC_User/Datastream/Calcium/CalciumCInterface.hxx @@ -71,22 +71,22 @@ template <> struct CalTimeType { il sera mappé sur le type int (si il est 32bits). Le type CORBA:LongLong est mappé sur le type long s'il est 64 bits sinon celà peut être un long long (s'il existe). */ -CALCIUM_C2CPP_INTERFACE_HXX_(intc,int,int,); -CALCIUM_C2CPP_INTERFACE_HXX_(long,long,long,); +CALCIUM_C2CPP_INTERFACE_HXX_(intc,int,int,) +CALCIUM_C2CPP_INTERFACE_HXX_(long,long,long,) -CALCIUM_C2CPP_INTERFACE_HXX_(integer,integer,cal_int,); -CALCIUM_C2CPP_INTERFACE_HXX_(int2integer,integer,int,); -CALCIUM_C2CPP_INTERFACE_HXX_(long2integer,integer, long,); +CALCIUM_C2CPP_INTERFACE_HXX_(integer,integer,cal_int,) +CALCIUM_C2CPP_INTERFACE_HXX_(int2integer,integer,int,) +CALCIUM_C2CPP_INTERFACE_HXX_(long2integer,integer, long,) -CALCIUM_C2CPP_INTERFACE_HXX_(float,float,float, ); -CALCIUM_C2CPP_INTERFACE_HXX_(double,double,double,); +CALCIUM_C2CPP_INTERFACE_HXX_(float,float,float, ) +CALCIUM_C2CPP_INTERFACE_HXX_(double,double,double,) -CALCIUM_C2CPP_INTERFACE_HXX_(float2double,double,float, ); +CALCIUM_C2CPP_INTERFACE_HXX_(float2double,double,float, ) /* Fonctionne mais essai suivant pour simplification de Calcium.c CALCIUM_C2CPP_INTERFACE_(bool,bool,);*/ -CALCIUM_C2CPP_INTERFACE_HXX_(bool,bool,int,); -CALCIUM_C2CPP_INTERFACE_HXX_(cplx,cplx,float,); -CALCIUM_C2CPP_INTERFACE_HXX_(str,str,char*,); +CALCIUM_C2CPP_INTERFACE_HXX_(bool,bool,int,) +CALCIUM_C2CPP_INTERFACE_HXX_(cplx,cplx,float,) +CALCIUM_C2CPP_INTERFACE_HXX_(str,str,char*,) /* Déclaration de ecp_fin */ extern "C" CalciumTypes::InfoType ecp_fin_ (void * component, int code); diff --git a/src/DSC/DSC_User/Datastream/Calcium/CalciumCouplingPolicy.cxx b/src/DSC/DSC_User/Datastream/Calcium/CalciumCouplingPolicy.cxx index fdb95d670..b099c9ca5 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/CalciumCouplingPolicy.cxx +++ b/src/DSC/DSC_User/Datastream/Calcium/CalciumCouplingPolicy.cxx @@ -33,14 +33,14 @@ CalciumCouplingPolicy::CalciumCouplingPolicy():_dependencyType(CalciumTypes::UND _interpolationSchem(CalciumTypes::L1_SCHEM), _extrapolationSchem(CalciumTypes::UNDEFINED_EXTRA_SCHEM), _alpha(0.0),_deltaT(CalciumTypes::EPSILON), - _disconnectDirective(CalciumTypes::UNDEFINED_DIRECTIVE){}; + _disconnectDirective(CalciumTypes::UNDEFINED_DIRECTIVE){} void CalciumCouplingPolicy::setDependencyType (CalciumTypes::DependencyType dependencyType) {_dependencyType=dependencyType;} CalciumTypes::DependencyType CalciumCouplingPolicy::getDependencyType () const { return _dependencyType;} void CalciumCouplingPolicy::setStorageLevel (size_t storageLevel) { MESSAGE( "CalciumCouplingPolicy::setStorageLevel: " << storageLevel ); - if ( storageLevel < 1 && (storageLevel != CalciumTypes::UNLIMITED_STORAGE_LEVEL) ) + if ( storageLevel < 1 && (storageLevel != (size_t)CalciumTypes::UNLIMITED_STORAGE_LEVEL) ) throw CalciumException(CalciumTypes::CPRENA,LOC("StorageLevel < 1 is not allowed")); _storageLevel = storageLevel; } @@ -88,8 +88,8 @@ void CalciumCouplingPolicy::setExtrapolationSchem (CalciumTypes::ExtrapolationSc _extrapolationSchem=extrapolationSchem; } -CalciumTypes::InterpolationSchem CalciumCouplingPolicy::getInterpolationSchem () const { return _interpolationSchem; }; -CalciumTypes::ExtrapolationSchem CalciumCouplingPolicy::getExtrapolationSchem () const { return _extrapolationSchem; }; +CalciumTypes::InterpolationSchem CalciumCouplingPolicy::getInterpolationSchem () const { return _interpolationSchem; } +CalciumTypes::ExtrapolationSchem CalciumCouplingPolicy::getExtrapolationSchem () const { return _extrapolationSchem; } CalciumCouplingPolicy::TimeType diff --git a/src/DSC/DSC_User/Datastream/Calcium/CalciumCouplingPolicy.hxx b/src/DSC/DSC_User/Datastream/Calcium/CalciumCouplingPolicy.hxx index f19d165c5..0a6df4de1 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/CalciumCouplingPolicy.hxx +++ b/src/DSC/DSC_User/Datastream/Calcium/CalciumCouplingPolicy.hxx @@ -168,11 +168,11 @@ struct CalciumCouplingPolicy::InternalDataIdContainer : public std::vector< std: template struct CalciumCouplingPolicy::BoundedDataIdProcessor{ - BoundedDataIdProcessor(const CouplingPolicy & couplingPolicy) {}; + BoundedDataIdProcessor(const CouplingPolicy & /*couplingPolicy*/) {}; template < typename Iterator, typename DataId > - void inline apply(typename iterator_t::value_type & data, - const DataId & dataId, - const Iterator & it1) const { + void inline apply(typename iterator_t::value_type & /*data*/, + const DataId & /*dataId*/, + const Iterator & /*it1*/) const { typedef typename iterator_t::value_type value_type; #ifdef MYDEBUG std::cout << "-------- Calcium Generic BoundedDataIdProcessor.apply() called " << std::endl; @@ -441,7 +441,7 @@ struct CalciumCouplingPolicy::EraseDataIdProcessor { std::cout << "-------- CalciumCouplingPolicy::eraseDataId, storedDatasSize : " << storedDatas.size() << std::endl; #endif - if ( _couplingPolicy._storageLevel == CalciumTypes::UNLIMITED_STORAGE_LEVEL ) return; + if ( _couplingPolicy._storageLevel == (size_t)CalciumTypes::UNLIMITED_STORAGE_LEVEL ) return; size_t storedDatasSize = storedDatas.size(); long s = storedDatasSize - _couplingPolicy._storageLevel; @@ -453,7 +453,7 @@ struct CalciumCouplingPolicy::EraseDataIdProcessor { storedDatas.erase(storedDatas.begin()); } // Si l'itérateur pointait sur une valeur que l'on vient de supprimer - if (dist < s ) { + if (dist < (size_t)s ) { throw(CalciumException(CalciumTypes::CPNTNULL,LOC(OSS()<< "StorageLevel management " << _couplingPolicy._storageLevel << " has just removed the data to send"))); diff --git a/src/DSC/DSC_User/Datastream/Calcium/CalciumCxxInterface.cxx b/src/DSC/DSC_User/Datastream/Calcium/CalciumCxxInterface.cxx index 9a55e32b2..0f7a3843d 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/CalciumCxxInterface.cxx +++ b/src/DSC/DSC_User/Datastream/Calcium/CalciumCxxInterface.cxx @@ -30,5 +30,5 @@ namespace CalciumInterface { -}; +} diff --git a/src/DSC/DSC_User/Datastream/Calcium/CalciumCxxInterface.hxx b/src/DSC/DSC_User/Datastream/Calcium/CalciumCxxInterface.hxx index b3c55ae47..2995e687a 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/CalciumCxxInterface.hxx +++ b/src/DSC/DSC_User/Datastream/Calcium/CalciumCxxInterface.hxx @@ -606,7 +606,7 @@ namespace CalciumInterface { #endif return; - }; + } template static void ecp_ecriture ( Superv_Component_i & component, @@ -618,7 +618,7 @@ namespace CalciumInterface { T1 const & data ) { ecp_ecriture (component,dependencyType,t,i,nomVar,bufferLength,data); - }; + } static inline void ecp_fini(Superv_Component_i & component,const std::string & nomVar,long const & i) @@ -677,7 +677,7 @@ namespace CalciumInterface { msg << "i<=" << i ; Engines_DSC_interface::writeEvent("CP_FINI",containerName,componentName,nomVar.c_str(),"",msg.str().c_str()); - }; + } static inline void ecp_fint(Superv_Component_i & component,const std::string & nomVar,double const & t) @@ -736,7 +736,7 @@ namespace CalciumInterface { msg << "t<=" << t ; Engines_DSC_interface::writeEvent("CP_FINT",containerName,componentName,nomVar.c_str(),"",msg.str().c_str()); - }; + } static inline void ecp_effi(Superv_Component_i & component,const std::string & nomVar,long const & i) @@ -795,7 +795,7 @@ namespace CalciumInterface { msg << "i>=" << i ; Engines_DSC_interface::writeEvent("CP_EFFI",containerName,componentName,nomVar.c_str(),"",msg.str().c_str()); - }; + } static inline void ecp_efft(Superv_Component_i & component,const std::string & nomVar,double const & t) @@ -854,8 +854,8 @@ namespace CalciumInterface { msg << "t>=" << t ; Engines_DSC_interface::writeEvent("CP_EFFT",containerName,componentName,nomVar.c_str(),"",msg.str().c_str()); - }; + } -}; +} #endif diff --git a/src/DSC/DSC_User/Datastream/Calcium/CalciumGenericProvidesPort.hxx b/src/DSC/DSC_User/Datastream/Calcium/CalciumGenericProvidesPort.hxx index 16c25ba8f..16f03573d 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/CalciumGenericProvidesPort.hxx +++ b/src/DSC/DSC_User/Datastream/Calcium/CalciumGenericProvidesPort.hxx @@ -145,7 +145,7 @@ virtual CORBA::Any* get_property(const char* name) \ ; \ \ - virtual void provides_port_changed(int connection_nbr, \ + virtual void provides_port_changed(int /*connection_nbr*/, \ const Engines::DSC::Message message) { \ if ( message == Engines::DSC::AddingConnection) \ { \ @@ -169,7 +169,7 @@ #define CALCIUM_GENERIC_PROVIDES_PORT_CXX(specificPortName) \ \ - specificPortName::~specificPortName(void) {}; \ + specificPortName::~specificPortName(void) {} \ \ void specificPortName::set_property(const char * name, const CORBA::Any& value) \ { \ @@ -237,7 +237,7 @@ throw Ports::NotDefined(); \ } \ return value; \ - }; + } #endif diff --git a/src/DSC/DSC_User/Datastream/Calcium/CalciumGenericUsesPort.hxx b/src/DSC/DSC_User/Datastream/Calcium/CalciumGenericUsesPort.hxx index 6dd5746a1..7d3518f30 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/CalciumGenericUsesPort.hxx +++ b/src/DSC/DSC_User/Datastream/Calcium/CalciumGenericUsesPort.hxx @@ -51,7 +51,7 @@ CalciumGenericUsesPort< DataManipulator,CorbaPortType, repositoryName >::disconn if (!this->_my_ports) throw DSC_Exception(LOC("There is no connected provides port to communicate with.")); - for(int i = 0; i < this->_my_ports->length(); i++) { + for(int i = 0; i < (int)this->_my_ports->length(); i++) { CorbaPortTypePtr port = CorbaPortType::_narrow((*this->_my_ports)[i]); try { #ifdef MYDEBUG diff --git a/src/DSC/DSC_User/Datastream/Calcium/calcium_destructors_port_uses.cxx b/src/DSC/DSC_User/Datastream/Calcium/calcium_destructors_port_uses.cxx index 5d3a48996..1f4c59374 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/calcium_destructors_port_uses.cxx +++ b/src/DSC/DSC_User/Datastream/Calcium/calcium_destructors_port_uses.cxx @@ -33,11 +33,11 @@ #include "calcium_logical_port_uses.hxx" #include "calcium_complex_port_uses.hxx" -calcium_real_port_uses::~calcium_real_port_uses(void) {}; -calcium_double_port_uses::~calcium_double_port_uses(void) {}; -calcium_integer_port_uses::~calcium_integer_port_uses(void) {}; -calcium_long_port_uses::~calcium_long_port_uses(void) {}; -calcium_intc_port_uses::~calcium_intc_port_uses(void) {}; -calcium_logical_port_uses::~calcium_logical_port_uses(void) {}; -calcium_complex_port_uses::~calcium_complex_port_uses(void) {}; -calcium_string_port_uses::~calcium_string_port_uses(void) {}; +calcium_real_port_uses::~calcium_real_port_uses(void) {} +calcium_double_port_uses::~calcium_double_port_uses(void) {} +calcium_integer_port_uses::~calcium_integer_port_uses(void) {} +calcium_long_port_uses::~calcium_long_port_uses(void) {} +calcium_intc_port_uses::~calcium_intc_port_uses(void) {} +calcium_logical_port_uses::~calcium_logical_port_uses(void) {} +calcium_complex_port_uses::~calcium_complex_port_uses(void) {} +calcium_string_port_uses::~calcium_string_port_uses(void) {} diff --git a/src/DSC/DSC_User/Datastream/Calcium/calcium_provides_port.hxx b/src/DSC/DSC_User/Datastream/Calcium/calcium_provides_port.hxx index 9f8e042d4..2507153b4 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/calcium_provides_port.hxx +++ b/src/DSC/DSC_User/Datastream/Calcium/calcium_provides_port.hxx @@ -63,7 +63,7 @@ public : virtual InterpolationSchem getInterpolationSchem () const =0; virtual ExtrapolationSchem getExtrapolationSchem () const =0; - virtual void calcium_erase (float t,long i, bool before) {}; + virtual void calcium_erase (float /*t*/,long /*i*/, bool /*before*/) {}; }; #endif diff --git a/src/DSC/DSC_User/Datastream/Calcium/calcium_uses_port.hxx b/src/DSC/DSC_User/Datastream/Calcium/calcium_uses_port.hxx index 2034e4594..533880831 100644 --- a/src/DSC/DSC_User/Datastream/Calcium/calcium_uses_port.hxx +++ b/src/DSC/DSC_User/Datastream/Calcium/calcium_uses_port.hxx @@ -37,7 +37,7 @@ class calcium_uses_port : public uses_port public : calcium_uses_port(); virtual ~calcium_uses_port(); - virtual void disconnect (bool provideLastGivenValue) {}; + virtual void disconnect (bool /*provideLastGivenValue*/) {}; }; #endif diff --git a/src/DSC/DSC_User/Datastream/CorbaTypeManipulator.hxx b/src/DSC/DSC_User/Datastream/CorbaTypeManipulator.hxx index 3747f7612..53073cfe6 100644 --- a/src/DSC/DSC_User/Datastream/CorbaTypeManipulator.hxx +++ b/src/DSC/DSC_User/Datastream/CorbaTypeManipulator.hxx @@ -178,7 +178,7 @@ public: // } // Operation de destruction d'une donnee: rien a faire car pas de memoire a liberer - static inline void delete_data(Type data) {} + static inline void delete_data(Type /*data*/) {} // Renvoie la taille de la donnée static inline size_t size(Type data) { @@ -325,7 +325,7 @@ public: InnerType *dataPtr = getPointer(data,false); - for (int i = 0; i< isize; ++i) + for (size_t i = 0; i< isize; ++i) idata[i]=dataPtr[i]; // Le mode de recopie suivant ne permet pas la conversion de type (ex int -> CORBA::Long) @@ -352,7 +352,7 @@ public: // Si idata[i] n'a pas été alloué suffisament grand, // il y a corruption de la mémoire - for (int i = 0; i< isize; ++i) + for (size_t i = 0; i< isize; ++i) strcpy(idata[i],dataPtr[i]); } diff --git a/src/DSC/DSC_User/Datastream/DisplayPair.hxx b/src/DSC/DSC_User/Datastream/DisplayPair.hxx index fecb4c6af..aa6d0f4d0 100644 --- a/src/DSC/DSC_User/Datastream/DisplayPair.hxx +++ b/src/DSC/DSC_User/Datastream/DisplayPair.hxx @@ -35,7 +35,7 @@ template std::ostream & operator <<(std::ostream & os, const std::pair & p) { os << "(" << p.first << "," << p.second << ")"; return os; -}; +} #endif diff --git a/src/DSC/DSC_User/Datastream/GenericPort.hxx b/src/DSC/DSC_User/Datastream/GenericPort.hxx index 3e95ef50d..aaf6fea6a 100644 --- a/src/DSC/DSC_User/Datastream/GenericPort.hxx +++ b/src/DSC/DSC_User/Datastream/GenericPort.hxx @@ -686,6 +686,6 @@ GenericPort::next(TimeType &t, // Du coup interaction potentielle entre le 0 copy et gestion des niveaux return dataToTransmit; -}; +} #endif diff --git a/src/DSC/DSC_User/Datastream/GenericUsesPort.hxx b/src/DSC/DSC_User/Datastream/GenericUsesPort.hxx index c1ab6b974..105e17805 100644 --- a/src/DSC/DSC_User/Datastream/GenericUsesPort.hxx +++ b/src/DSC/DSC_User/Datastream/GenericUsesPort.hxx @@ -37,11 +37,11 @@ #include "DSC_Exception.hxx" -// #define GENERATE_USES_PORT(dataManip,portType,portName) \ -// const char * _repository_##portType##_name_ = "IDL:Ports/##portType##:1.0"; \ -// GenericUsesPort< dataManip, portType, _repository_##portType##_name_ > portName; +/* #define GENERATE_USES_PORT(dataManip,portType,portName) \ + const char * _repository_##portType##_name_ = "IDL:Ports/##portType##:1.0"; \ + GenericUsesPort< dataManip, portType, _repository_##portType##_name_ > portName; -//ex : GENERATE_USES_PORT(Ports::Data_Short_Port,data_short_port); +ex : GENERATE_USES_PORT(Ports::Data_Short_Port,data_short_port);*/ template @@ -134,7 +134,7 @@ template ::uses_port_changed(Engines::DSC::uses_port * new_uses_port, - const Engines::DSC::Message message) + const Engines::DSC::Message /*message*/) { if (_my_ports) delete _my_ports; diff --git a/src/DSC/DSC_User/Datastream/fake.cc b/src/DSC/DSC_User/Datastream/fake.cc index 3211ee31a..d1d07610f 100644 --- a/src/DSC/DSC_User/Datastream/fake.cc +++ b/src/DSC/DSC_User/Datastream/fake.cc @@ -26,4 +26,4 @@ // void fake_method(void) { // int fake_int; -}; +} diff --git a/src/DSC/DSC_User/Superv_Component_i.cxx b/src/DSC/DSC_User/Superv_Component_i.cxx index 0822c66de..a5f81188f 100644 --- a/src/DSC/DSC_User/Superv_Component_i.cxx +++ b/src/DSC/DSC_User/Superv_Component_i.cxx @@ -26,15 +26,15 @@ // #include "Superv_Component_i.hxx" -DSC_EXCEPTION_CXX(Superv_Component_i,BadFabType); -DSC_EXCEPTION_CXX(Superv_Component_i,BadType); -DSC_EXCEPTION_CXX(Superv_Component_i,BadCast); -DSC_EXCEPTION_CXX(Superv_Component_i,UnexpectedState); -DSC_EXCEPTION_CXX(Superv_Component_i,PortAlreadyDefined); -DSC_EXCEPTION_CXX(Superv_Component_i,PortNotDefined); -DSC_EXCEPTION_CXX(Superv_Component_i,PortNotConnected); -DSC_EXCEPTION_CXX(Superv_Component_i,NilPort); -DSC_EXCEPTION_CXX(Superv_Component_i,BadProperty); +DSC_EXCEPTION_CXX(Superv_Component_i,BadFabType) +DSC_EXCEPTION_CXX(Superv_Component_i,BadType) +DSC_EXCEPTION_CXX(Superv_Component_i,BadCast) +DSC_EXCEPTION_CXX(Superv_Component_i,UnexpectedState) +DSC_EXCEPTION_CXX(Superv_Component_i,PortAlreadyDefined) +DSC_EXCEPTION_CXX(Superv_Component_i,PortNotDefined) +DSC_EXCEPTION_CXX(Superv_Component_i,PortNotConnected) +DSC_EXCEPTION_CXX(Superv_Component_i,NilPort) +DSC_EXCEPTION_CXX(Superv_Component_i,BadProperty) std::map Superv_Component_i::_factory_map; long Superv_Component_i::dscTimeOut=0; @@ -48,6 +48,7 @@ Superv_Component_i::Superv_Component_i(CORBA::ORB_ptr orb, bool notif) : Engines_DSC_i(orb, poa, contId, instanceName, interfaceName) { + SALOME_UNUSED(notif); #ifdef MYDEBUG std::cerr << "--Superv_Component_i : MARK 1 ---- " << instanceName << "----" << std::endl; #endif @@ -315,7 +316,7 @@ Superv_Component_i::uses_port_changed(const char* uses_port_name, void Superv_Component_i::get_uses_port_names(std::vector & port_names, const std::string servicename) const { - + SALOME_UNUSED(servicename); port_names.reserve(my_superv_ports.size()); superv_ports::const_iterator it; diff --git a/src/DSC/DSC_User/Superv_Component_i.hxx b/src/DSC/DSC_User/Superv_Component_i.hxx index 43972c670..43aa45b5e 100644 --- a/src/DSC/DSC_User/Superv_Component_i.hxx +++ b/src/DSC/DSC_User/Superv_Component_i.hxx @@ -32,6 +32,7 @@ #include "uses_port.hxx" #include "provides_port.hxx" #include "port_factory.hxx" +#include "Basics_Utils.hxx" #include "DSC_Exception.hxx" #include @@ -73,15 +74,15 @@ public: // Exceptions declarations. // There are defined on the Superv_Component_i.cxx to avoid problems // from dlopen. - DSC_EXCEPTION(BadFabType); - DSC_EXCEPTION(BadType); - DSC_EXCEPTION(BadCast); - DSC_EXCEPTION(UnexpectedState); - DSC_EXCEPTION(PortAlreadyDefined); - DSC_EXCEPTION(PortNotDefined); - DSC_EXCEPTION(PortNotConnected); - DSC_EXCEPTION(NilPort); - DSC_EXCEPTION(BadProperty); + DSC_EXCEPTION(BadFabType) + DSC_EXCEPTION(BadType) + DSC_EXCEPTION(BadCast) + DSC_EXCEPTION(UnexpectedState) + DSC_EXCEPTION(PortAlreadyDefined) + DSC_EXCEPTION(PortNotDefined) + DSC_EXCEPTION(PortNotConnected) + DSC_EXCEPTION(NilPort) + DSC_EXCEPTION(BadProperty) /*! * \warning currently disabled. @@ -93,7 +94,7 @@ public: * \warning currently disabled. */ virtual provides_port * create_provides_data_and_control_port(const char* port_type) - {return NULL;} + {SALOME_UNUSED(port_type);return NULL;} /*! * \warning currently disabled. @@ -105,7 +106,7 @@ public: * \warning currently disabled. */ virtual uses_port * create_uses_data_and_control_port(const char* port_type) - {return NULL;} + {SALOME_UNUSED(port_type);return NULL;} /*! * This method permits to create a provides port provided by the platform. @@ -269,6 +270,8 @@ public: virtual CORBA::Boolean init_service_with_multiple(const char* service_name, const Engines::Superv_Component::seq_multiple_param & params) { + SALOME_UNUSED(service_name); + SALOME_UNUSED(params); return true; } @@ -358,7 +361,7 @@ Superv_Component_i::add_port(const char * port_fab_type, << port_type)); return retPort; -}; +} template SpecificPortType * @@ -404,7 +407,7 @@ Superv_Component_i::get_port( const char * port_name) } return retPort; -}; +} #endif diff --git a/src/DSC/DSC_User/provides_port.hxx b/src/DSC/DSC_User/provides_port.hxx index 0205e3f91..25e4ae768 100644 --- a/src/DSC/DSC_User/provides_port.hxx +++ b/src/DSC/DSC_User/provides_port.hxx @@ -57,8 +57,8 @@ class provides_port : public base_port * \param connection_nbr current connection number. * \param message message associated with this connection. */ - virtual void provides_port_changed(int connection_nbr, - const Engines::DSC::Message message) {} + virtual void provides_port_changed(int /*connection_nbr*/, + const Engines::DSC::Message /*message*/) {} }; diff --git a/src/GenericObj/SALOME_GenericObj_i.cc b/src/GenericObj/SALOME_GenericObj_i.cc index 0d302636e..e257df6cf 100644 --- a/src/GenericObj/SALOME_GenericObj_i.cc +++ b/src/GenericObj/SALOME_GenericObj_i.cc @@ -150,4 +150,4 @@ namespace SALOME UnRegister(); } -}; // end of namespace SALOME +} // end of namespace SALOME diff --git a/src/HDFPersist/HDFconvert.cc b/src/HDFPersist/HDFconvert.cc index 665f86a45..e2c74e2f5 100644 --- a/src/HDFPersist/HDFconvert.cc +++ b/src/HDFPersist/HDFconvert.cc @@ -124,4 +124,4 @@ int HDFConvert::FromAscii(const std::string& file, const HDFcontainerObject & hd // TODO: return or ? return static_cast(length); -}; +} diff --git a/src/HDFPersist/HDFgroup.cc b/src/HDFPersist/HDFgroup.cc index 2db76d5ca..e6c888e33 100644 --- a/src/HDFPersist/HDFgroup.cc +++ b/src/HDFPersist/HDFgroup.cc @@ -46,7 +46,7 @@ HDFgroup::HDFgroup(const char *name, HDFcontainerObject *father) _father->AddSon(this); _mid = -1; _attribute = NULL; -}; +} void HDFgroup::CreateOnDisk() { diff --git a/src/KernelHelpers/SALOMEDS_DriverDefaultImpl.cxx b/src/KernelHelpers/SALOMEDS_DriverDefaultImpl.cxx index e2a444396..7f764836f 100644 --- a/src/KernelHelpers/SALOMEDS_DriverDefaultImpl.cxx +++ b/src/KernelHelpers/SALOMEDS_DriverDefaultImpl.cxx @@ -24,27 +24,27 @@ //=========================================================================== - SALOMEDS_DriverDefaultImpl::SALOMEDS_DriverDefaultImpl(CORBA::ORB_ptr orb, - PortableServer::POA_ptr poa, - PortableServer::ObjectId * contId, - const char *instanceName, - const char *interfaceName) + SALOMEDS_DriverDefaultImpl::SALOMEDS_DriverDefaultImpl(CORBA::ORB_ptr /*orb*/, + PortableServer::POA_ptr /*poa*/, + PortableServer::ObjectId * /*contId*/, + const char * /*instanceName*/, + const char * /*interfaceName*/) // :Engines_Component_i(orb, poa, contId, instanceName, interfaceName) { MESSAGE("SALOMEDS_DriverDefaultImpl::SALOMEDS_DriverDefaultImpl : "); - }; + } //=========================================================================== SALOMEDS_DriverDefaultImpl::~SALOMEDS_DriverDefaultImpl() { MESSAGE("SALOMEDS_DriverDefaultImpl::~SALOMEDS_DriverDefaultImpl"); - }; + } //=========================================================================== - CORBA::Boolean SALOMEDS_DriverDefaultImpl::Load(SALOMEDS::SComponent_ptr theComponent, - const SALOMEDS::TMPFile & theStream, - const char* theURL, - bool isMultiFile) + CORBA::Boolean SALOMEDS_DriverDefaultImpl::Load(SALOMEDS::SComponent_ptr /*theComponent*/, + const SALOMEDS::TMPFile & /*theStream*/, + const char* /*theURL*/, + bool /*isMultiFile*/) { MESSAGE("--------------------------------------"); MESSAGE("--------------------------------------"); @@ -55,13 +55,13 @@ MESSAGE("--------------------------------------"); MESSAGE("--------------------------------------"); return false; - }; + } //=========================================================================== - CORBA::Boolean SALOMEDS_DriverDefaultImpl::LoadASCII(SALOMEDS::SComponent_ptr theComponent, - const SALOMEDS::TMPFile & theStream, - const char* theURL, - bool isMultiFile) + CORBA::Boolean SALOMEDS_DriverDefaultImpl::LoadASCII(SALOMEDS::SComponent_ptr /*theComponent*/, + const SALOMEDS::TMPFile & /*theStream*/, + const char* /*theURL*/, + bool /*isMultiFile*/) { MESSAGE("--------------------------------------"); MESSAGE("--------------------------------------"); @@ -72,13 +72,13 @@ MESSAGE("--------------------------------------"); MESSAGE("--------------------------------------"); return false; - }; + } //=========================================================================== - char* SALOMEDS_DriverDefaultImpl::LocalPersistentIDToIOR(SALOMEDS::SObject_ptr theSObject, - const char* aLocalPersistentID, - CORBA::Boolean isMultiFile, - CORBA::Boolean isASCII) + char* SALOMEDS_DriverDefaultImpl::LocalPersistentIDToIOR(SALOMEDS::SObject_ptr /*theSObject*/, + const char* /*aLocalPersistentID*/, + CORBA::Boolean /*isMultiFile*/, + CORBA::Boolean /*isASCII*/) { MESSAGE("--------------------------------------"); MESSAGE("--------------------------------------"); @@ -90,12 +90,12 @@ MESSAGE("--------------------------------------"); CORBA::String_var aString(""); return aString._retn(); - }; + } //=========================================================================== - SALOMEDS::TMPFile* SALOMEDS_DriverDefaultImpl::Save(SALOMEDS::SComponent_ptr theComponent, - const char* theURL, - bool isMultiFile) + SALOMEDS::TMPFile* SALOMEDS_DriverDefaultImpl::Save(SALOMEDS::SComponent_ptr /*theComponent*/, + const char* /*theURL*/, + bool /*isMultiFile*/) { MESSAGE("--------------------------------------"); MESSAGE("--------------------------------------"); @@ -107,12 +107,12 @@ MESSAGE("--------------------------------------"); SALOMEDS::TMPFile_var aStreamFile = new SALOMEDS::TMPFile(0); return aStreamFile._retn(); - }; + } //=========================================================================== - SALOMEDS::TMPFile* SALOMEDS_DriverDefaultImpl::SaveASCII(SALOMEDS::SComponent_ptr theComponent, - const char* theURL, - bool isMultiFile) + SALOMEDS::TMPFile* SALOMEDS_DriverDefaultImpl::SaveASCII(SALOMEDS::SComponent_ptr /*theComponent*/, + const char* /*theURL*/, + bool /*isMultiFile*/) { MESSAGE("--------------------------------------"); MESSAGE("--------------------------------------"); @@ -124,13 +124,13 @@ MESSAGE("--------------------------------------"); SALOMEDS::TMPFile_var aStreamFile = new SALOMEDS::TMPFile(0); return aStreamFile._retn(); - }; + } //=========================================================================== - char* SALOMEDS_DriverDefaultImpl::IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject, - const char* IORString, - CORBA::Boolean isMultiFile, - CORBA::Boolean isASCII) + char* SALOMEDS_DriverDefaultImpl::IORToLocalPersistentID(SALOMEDS::SObject_ptr /*theSObject*/, + const char* /*IORString*/, + CORBA::Boolean /*isMultiFile*/, + CORBA::Boolean /*isASCII*/) { MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); @@ -142,16 +142,16 @@ MESSAGE("-----------------------------------------"); CORBA::String_var aString(""); return aString._retn(); - }; + } //=========================================================================== - void SALOMEDS_DriverDefaultImpl::Close(SALOMEDS::SComponent_ptr theComponent) + void SALOMEDS_DriverDefaultImpl::Close(SALOMEDS::SComponent_ptr /*theComponent*/) { MESSAGE("------------------------"); MESSAGE("SALOMEDS_DriverDefaultImpl::Close"); MESSAGE("------------------------"); - }; + } //=========================================================================== char* SALOMEDS_DriverDefaultImpl::ComponentDataType() @@ -165,10 +165,10 @@ MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); return CORBA::string_dup("J aurais du nommer mon type prefere"); - }; + } //=========================================================================== - bool SALOMEDS_DriverDefaultImpl::CanPublishInStudy(CORBA::Object_ptr theIOR) + bool SALOMEDS_DriverDefaultImpl::CanPublishInStudy(CORBA::Object_ptr /*theIOR*/) { MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); @@ -179,12 +179,12 @@ MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); return false; - }; + } //=========================================================================== - SALOMEDS::SObject_ptr SALOMEDS_DriverDefaultImpl::PublishInStudy(SALOMEDS::SObject_ptr theSObject, - CORBA::Object_ptr theObject, - const char* theName) + SALOMEDS::SObject_ptr SALOMEDS_DriverDefaultImpl::PublishInStudy(SALOMEDS::SObject_ptr /*theSObject*/, + CORBA::Object_ptr /*theObject*/, + const char* /* theName*/) { MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); @@ -196,10 +196,10 @@ MESSAGE("-----------------------------------------"); SALOMEDS::SObject_var aResultSO; return aResultSO._retn(); - }; + } //=========================================================================== - CORBA::Boolean SALOMEDS_DriverDefaultImpl::CanCopy(SALOMEDS::SObject_ptr theObject) + CORBA::Boolean SALOMEDS_DriverDefaultImpl::CanCopy(SALOMEDS::SObject_ptr /*theObject*/) { MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); @@ -211,11 +211,11 @@ MESSAGE("-----------------------------------------"); //return false; return true; - }; + } //=========================================================================== - SALOMEDS::TMPFile* SALOMEDS_DriverDefaultImpl::CopyFrom(SALOMEDS::SObject_ptr theObject, - CORBA::Long& theObjectID) + SALOMEDS::TMPFile* SALOMEDS_DriverDefaultImpl::CopyFrom(SALOMEDS::SObject_ptr /*theObject*/, + CORBA::Long& /*theObjectID*/) { MESSAGE("--------------------------------------"); MESSAGE("--------------------------------------"); @@ -227,12 +227,12 @@ MESSAGE("--------------------------------------"); SALOMEDS::TMPFile_var aStreamFile = new SALOMEDS::TMPFile(0); return aStreamFile._retn(); -}; +} //=========================================================================== - SALOMEDS::SObject_ptr SALOMEDS_DriverDefaultImpl::PasteInto( const SALOMEDS::TMPFile & theStream, - CORBA::Long theObjectID, - SALOMEDS::SObject_ptr theSObject) + SALOMEDS::SObject_ptr SALOMEDS_DriverDefaultImpl::PasteInto( const SALOMEDS::TMPFile & /*theStream*/, + CORBA::Long /*theObjectID*/, + SALOMEDS::SObject_ptr /*theSObject*/) { MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); @@ -244,11 +244,11 @@ MESSAGE("-----------------------------------------"); SALOMEDS::SObject_var aResultSO; return aResultSO._retn(); - }; + } //=========================================================================== - CORBA::Boolean SALOMEDS_DriverDefaultImpl::CanPaste ( const char *theComponentName, - CORBA::Long theObjectID) + CORBA::Boolean SALOMEDS_DriverDefaultImpl::CanPaste ( const char * /*theComponentName*/, + CORBA::Long /*theObjectID*/) { MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); @@ -259,6 +259,6 @@ MESSAGE("-----------------------------------------"); MESSAGE("-----------------------------------------"); return false; - }; + } diff --git a/src/KernelHelpers/SALOMEDS_DriverDefaultImpl.hxx b/src/KernelHelpers/SALOMEDS_DriverDefaultImpl.hxx index 15ea32be2..58f8a1f04 100644 --- a/src/KernelHelpers/SALOMEDS_DriverDefaultImpl.hxx +++ b/src/KernelHelpers/SALOMEDS_DriverDefaultImpl.hxx @@ -40,11 +40,11 @@ class KERNELHELPERS_EXPORT SALOMEDS_DriverDefaultImpl: SALOMEDS_DriverDefaultImpl(); public: - SALOMEDS_DriverDefaultImpl(CORBA::ORB_ptr orb, - PortableServer::POA_ptr poa, - PortableServer::ObjectId * contId, - const char *instanceName, - const char *interfaceName); + SALOMEDS_DriverDefaultImpl(CORBA::ORB_ptr /*orb*/, + PortableServer::POA_ptr /*poa*/, + PortableServer::ObjectId * /*contId*/, + const char * /*instanceName*/, + const char * /*interfaceName*/); virtual ~SALOMEDS_DriverDefaultImpl(); @@ -54,13 +54,13 @@ class KERNELHELPERS_EXPORT SALOMEDS_DriverDefaultImpl: //--------------------------------------------- //virtual SALOMEDS::TMPFile* Save(SALOMEDS::SComponent_ptr theComponent, - SALOMEDS::TMPFile* Save(SALOMEDS::SComponent_ptr theComponent, - const char* theURL, - bool isMultiFile); + SALOMEDS::TMPFile* Save(SALOMEDS::SComponent_ptr /*theComponent*/, + const char* /*theURL*/, + bool /*isMultiFile*/); - virtual SALOMEDS::TMPFile* SaveASCII(SALOMEDS::SComponent_ptr theComponent, - const char* theURL, - bool isMultiFile); + virtual SALOMEDS::TMPFile* SaveASCII(SALOMEDS::SComponent_ptr /*theComponent*/, + const char* /*theURL*/, + bool /*isMultiFile*/); virtual bool Load(SALOMEDS::SComponent_ptr, const SALOMEDS::TMPFile &, @@ -72,36 +72,36 @@ class KERNELHELPERS_EXPORT SALOMEDS_DriverDefaultImpl: const char* theURL, bool isMultiFile); - virtual void Close(SALOMEDS::SComponent_ptr IORSComponent); + virtual void Close(SALOMEDS::SComponent_ptr /*IORSComponent*/); virtual char* ComponentDataType(); - virtual char* IORToLocalPersistentID(SALOMEDS::SObject_ptr theSObject, - const char* IORString, - CORBA::Boolean isMultiFile, - CORBA::Boolean isASCII); + virtual char* IORToLocalPersistentID(SALOMEDS::SObject_ptr /*theSObject*/, + const char* /*IORString*/, + CORBA::Boolean /*isMultiFile*/, + CORBA::Boolean /*isASCII*/); - virtual char* LocalPersistentIDToIOR(SALOMEDS::SObject_ptr theSObject, - const char* aLocalPersistentID, - CORBA::Boolean isMultiFile, - CORBA::Boolean isASCII); + virtual char* LocalPersistentIDToIOR(SALOMEDS::SObject_ptr /*theSObject*/, + const char* /*aLocalPersistentID*/, + CORBA::Boolean /*isMultiFile*/, + CORBA::Boolean /*isASCII*/); - virtual bool CanPublishInStudy(CORBA::Object_ptr theIOR); + virtual bool CanPublishInStudy(CORBA::Object_ptr /*theIOR*/); - virtual SALOMEDS::SObject_ptr PublishInStudy(SALOMEDS::SObject_ptr theSObject, - CORBA::Object_ptr theObject, - const char* theName); + virtual SALOMEDS::SObject_ptr PublishInStudy(SALOMEDS::SObject_ptr /*theSObject*/, + CORBA::Object_ptr /*theObject*/, + const char* /*theName*/); - virtual CORBA::Boolean CanCopy(SALOMEDS::SObject_ptr theObject); + virtual CORBA::Boolean CanCopy(SALOMEDS::SObject_ptr /*theObject*/); - virtual SALOMEDS::TMPFile* CopyFrom(SALOMEDS::SObject_ptr theObject, - CORBA::Long& theObjectID); + virtual SALOMEDS::TMPFile* CopyFrom(SALOMEDS::SObject_ptr /*theObject*/, + CORBA::Long& /*theObjectID*/); - virtual CORBA::Boolean CanPaste(const char* theComponentName, - CORBA::Long theObjectID); + virtual CORBA::Boolean CanPaste(const char* /*theComponentName*/, + CORBA::Long /*theObjectID*/); - virtual SALOMEDS::SObject_ptr PasteInto(const SALOMEDS::TMPFile& theStream, - CORBA::Long theObjectID, - SALOMEDS::SObject_ptr theObject); + virtual SALOMEDS::SObject_ptr PasteInto(const SALOMEDS::TMPFile& /*theStream*/, + CORBA::Long /*theObjectID*/, + SALOMEDS::SObject_ptr /*theObject*/); }; #endif diff --git a/src/Launcher/SALOME_ExternalServerHandler.cxx b/src/Launcher/SALOME_ExternalServerHandler.cxx index 3e9648fa9..049697f81 100644 --- a/src/Launcher/SALOME_ExternalServerHandler.cxx +++ b/src/Launcher/SALOME_ExternalServerHandler.cxx @@ -127,7 +127,7 @@ SALOME::LongVec *SALOME_ExternalServerHandler::listOfChildrenPID() std::vector pids(pyh->evalVL(oss.str())); std::size_t sz(pids.size()); ret->length(sz); - for(auto i=0;i loes(ListOfExternalServersCpp(_NS)); std::size_t sz(loes.size()); ret->length((_CORBA_ULong)sz); //!< TODO: conversion from size_t to _CORBA_ULong - for(auto i = 0; ishutdown(0); -}; +} diff --git a/src/NamingService/SALOME_NamingService.cxx b/src/NamingService/SALOME_NamingService.cxx index 8ec505cbd..805d29d9c 100644 --- a/src/NamingService/SALOME_NamingService.cxx +++ b/src/NamingService/SALOME_NamingService.cxx @@ -257,8 +257,8 @@ void SALOME_NamingService::Register(CORBA::Object_ptr ObjRef, // be recorded size_t sizePath = splitPath.size(); - if (sizePath > dimension_resultat){ - ASSERT(sizePath == dimension_resultat+1); + if (sizePath > (size_t)dimension_resultat){ + ASSERT(sizePath == (size_t)dimension_resultat+1); context_name.length(1); try{ @@ -1177,9 +1177,9 @@ void SALOME_NamingService::Destroy_Name(const char* Path) // be destroyed size_t sizePath = splitPath.size(); - if (sizePath > dimension_resultat) + if (sizePath > (size_t)dimension_resultat) { - ASSERT(sizePath == dimension_resultat+1); + ASSERT(sizePath == (size_t)dimension_resultat+1); context_name.length(1); try @@ -1512,11 +1512,11 @@ SALOME_NamingService::_createContextNameDir(std::string path, dim = splitPath.size(); // directories and final object context_name.length(static_cast(dim)); - for (int i=0; i myValue.size()) throw DFexception("Out of range"); + if(Index <= 0 || Index > (int)myValue.size()) throw DFexception("Out of range"); // TODO: mismatch signed/unsigned myValue[Index-1] = Value; @@ -142,7 +142,7 @@ void SALOMEDSImpl_AttributeSequenceOfInteger::Remove(const int Index) CheckLocked(); Backup(); - if(Index <= 0 || Index > myValue.size()) throw DFexception("Out of range"); + if(Index <= 0 || Index > (int)myValue.size()) throw DFexception("Out of range"); // TODO: mismatch signed/unsigned typedef std::vector::iterator VI; int i = 1; @@ -162,7 +162,7 @@ int SALOMEDSImpl_AttributeSequenceOfInteger::Length() } int SALOMEDSImpl_AttributeSequenceOfInteger::Value(const int Index) { - if(Index <= 0 || Index > myValue.size()) throw DFexception("Out of range"); + if(Index <= 0 || Index > (int)myValue.size()) throw DFexception("Out of range"); // TODO: mismatch signed/unsigned return myValue[Index-1]; } diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeSequenceOfReal.cxx b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeSequenceOfReal.cxx index 263d72845..8e9cc8c4a 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeSequenceOfReal.cxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeSequenceOfReal.cxx @@ -123,7 +123,7 @@ void SALOMEDSImpl_AttributeSequenceOfReal::ChangeValue(const int Index,const dou CheckLocked(); Backup(); - if(Index <= 0 || Index > myValue.size()) throw DFexception("Out of range"); + if(Index <= 0 || Index > (int)myValue.size()) throw DFexception("Out of range"); // TODO: mismatch signed/unsigned myValue[Index-1] = Value; @@ -144,7 +144,7 @@ void SALOMEDSImpl_AttributeSequenceOfReal::Remove(const int Index) CheckLocked(); Backup(); - if(Index <= 0 || Index > myValue.size()) throw DFexception("Out of range"); + if(Index <= 0 || Index > (int)myValue.size()) throw DFexception("Out of range"); // TODO: mismatch signed/unsigned typedef std::vector::iterator VI; int i = 1; @@ -165,7 +165,7 @@ int SALOMEDSImpl_AttributeSequenceOfReal::Length() double SALOMEDSImpl_AttributeSequenceOfReal::Value(const int Index) { - if(Index <= 0 || Index > myValue.size()) throw DFexception("Out of range"); + if(Index <= 0 || Index > (int)myValue.size()) throw DFexception("Out of range"); // TODO: mismatch signed/unsigned return myValue[Index-1]; } diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeStudyProperties.cxx b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeStudyProperties.cxx index 9703eeddd..d84a59bd9 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeStudyProperties.cxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeStudyProperties.cxx @@ -224,7 +224,7 @@ void SALOMEDSImpl_AttributeStudyProperties::Paste(DF_Attribute* into) aProp->Init(); int i; - for(i = 0; i < myUserName.size(); i++) { + for(i = 0; i < (int)myUserName.size(); i++) { //TODO: mismatch signed/unsigned aProp->SetModification(myUserName[i], myMinute[i], myHour[i], myDay[i], myMonth[i], myYear[i]); @@ -243,7 +243,7 @@ std::string SALOMEDSImpl_AttributeStudyProperties::Save() std::vector aMinutes, aHours, aDays, aMonths, aYears; GetModifications(aNames, aMinutes, aHours, aDays, aMonths, aYears); - size_t aLength, anIndex, unitsSize = 0, commentSize = 0;; + int aLength, anIndex, unitsSize = 0, commentSize = 0;; for (aLength = 0, anIndex = aNames.size()-1; anIndex >= 0; anIndex--) aLength += aNames[anIndex].size() + 1; @@ -416,7 +416,7 @@ void SALOMEDSImpl_AttributeStudyProperties::Load(const std::string& value) // - yyyy: year = 4 bytes // - name: user's name = arbitrary value, minimal length is 0 bytes // - 1 : records delimiter = 1 byte - for (anIndex = 2; anIndex + 13 < value.size() ;) { + for (anIndex = 2; anIndex + 13 < (int)value.size() ;) { //TODO: mismatch signed/unsigned char str[10]; int aMinute, aHour, aDay, aMonth, aYear; str[0] = aCopy[anIndex++]; @@ -449,12 +449,12 @@ void SALOMEDSImpl_AttributeStudyProperties::Load(const std::string& value) anIndex += aNameSize + 1; //Check end of the modifications section - if(anIndex < value.size() && aCopy[anIndex] == 30) + if(anIndex < (int)value.size() && aCopy[anIndex] == 30) //TODO: mismatch signed/unsigned break; } //Case when study contains units and comment properties - if( anIndex < value.size() ) { + if( anIndex < (int)value.size() ) { //TODO: mismatch signed/unsigned anIndex++; //skip the delimiter of the sections: char(30) int unitsSize; for(unitsSize = 0; aCopy[anIndex+unitsSize] != 1; unitsSize++); @@ -482,8 +482,8 @@ void SALOMEDSImpl_AttributeStudyProperties::Load(const std::string& value) } //Case when study contains components versions - if( anIndex < value.size() ) { - while ( anIndex < value.size() && aCopy[anIndex] != 0 ) { + if( anIndex < (int)value.size() ) { //TODO: mismatch signed/unsigned + while ( anIndex < (int)value.size() && aCopy[anIndex] != 0 ) { //TODO: mismatch signed/unsigned int modSize; for(modSize = 0; aCopy[anIndex+modSize] != '='; modSize++); int verSize; diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfInteger.cxx b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfInteger.cxx index f4e406068..a98a09e31 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfInteger.cxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfInteger.cxx @@ -92,7 +92,7 @@ void SALOMEDSImpl_AttributeTableOfInteger::SetNbColumns(const int theNbColumns) myNbColumns = theNbColumns; - while (myCols.size() < myNbColumns) { // append empty columns titles + while ((int)myCols.size() < myNbColumns) { // append empty columns titles // TODO: mismatch signed/unsigned myCols.push_back(std::string("")); } @@ -117,11 +117,11 @@ void SALOMEDSImpl_AttributeTableOfInteger::SetRowData(const int theRow, const std::vector& theData) { CheckLocked(); - if(theData.size() > myNbColumns) SetNbColumns((int)theData.size()); //!< TODO: conversion from size_t to const int, possible loss of data + if((int)theData.size() > myNbColumns) SetNbColumns((int)theData.size()); //!< TODO: conversion from size_t to const int, possible loss of data Backup(); - while (myRows.size() < theRow) { // append new row titles + while ((int)myRows.size() < theRow) { // append new row titles // TODO: mismatch signed/unsigned myRows.push_back(std::string("")); } @@ -180,7 +180,7 @@ void SALOMEDSImpl_AttributeTableOfInteger::SetRowUnit(const int theRow, void SALOMEDSImpl_AttributeTableOfInteger::SetRowUnits(const std::vector& theUnits) { - if (theUnits.size() != GetNbRows()) throw DFexception("Invalid number of rows"); + if ((int)theUnits.size() != GetNbRows()) throw DFexception("Invalid number of rows"); // TODO: mismatch signed/unsigned size_t aLength = theUnits.size(), i; for(i = 1; i <= aLength; i++) SetRowUnit((int)i, theUnits[i-1]); //!< TODO: conversion from size_t to int @@ -197,7 +197,7 @@ std::vector SALOMEDSImpl_AttributeTableOfInteger::GetRowUnits() void SALOMEDSImpl_AttributeTableOfInteger::SetRowTitles(const std::vector& theTitles) { - if (theTitles.size() != GetNbRows()) throw DFexception("Invalid number of rows"); + if ((int)theTitles.size() != GetNbRows()) throw DFexception("Invalid number of rows"); //TODO: mismatch signed/unsigned size_t aLength = theTitles.size(), i; for(i = 1; i <= aLength; i++) SetRowTitle((int)i, theTitles[i-1]); //!< TODO: conversion from size_t to int @@ -449,7 +449,7 @@ std::string SALOMEDSImpl_AttributeTableOfInteger::Save() //Title l = myTitle.size(); - sprintf(buffer, "%Iu\n", l); + sprintf(buffer, "%u\n", l); aString+=buffer; for(i=0; ifirst, p->second); diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfReal.cxx b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfReal.cxx index 229394e6a..5ba44468d 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfReal.cxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfReal.cxx @@ -447,7 +447,7 @@ std::string SALOMEDSImpl_AttributeTableOfReal::Save() //Title l = myTitle.size(); - sprintf(buffer, "%Iu\n", l); + sprintf(buffer, "%zu\n", l); aString+=buffer; for(i=0; ifirst, p->second); diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfString.cxx b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfString.cxx index 269d8614d..7808991e5 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfString.cxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_AttributeTableOfString.cxx @@ -460,7 +460,7 @@ std::string SALOMEDSImpl_AttributeTableOfString::Save() //Row titles for(i=0; isecond.size()) { // check empty string in the value table @@ -601,12 +601,12 @@ std::vector SALOMEDSImpl_AttributeTableOfString::SortRow(const int theRow, } result = indices; - for ( int col = 0; col < indices.size(); col++ ) { + for ( int col = 0; col < (int)indices.size(); col++ ) { //TODO: mismatch signed/unsigned int idx = indices[col]; if ( col+1 == idx ) continue; SwapCells(theRow, col+1, theRow, idx); int idx1 = 0; - for ( int i = col+1; i < indices.size() && idx1 == 0; i++) + for ( int i = col+1; i < (int)indices.size() && idx1 == 0; i++) //TODO: mismatch signed/unsigned if ( indices[i] == col+1 ) idx1 = i; indices[idx1] = idx; } @@ -641,12 +641,12 @@ std::vector SALOMEDSImpl_AttributeTableOfString::SortColumn(const int theCo } result = indices; - for ( int row = 0; row < indices.size(); row++ ) { + for ( int row = 0; row < (int)indices.size(); row++ ) { //TODO: mismatch signed/unsigned int idx = indices[row]; if ( row+1 == idx ) continue; SwapCells(row+1, theColumn, idx, theColumn); int idx1 = 0; - for ( int i = row+1; i < indices.size() && idx1 == 0; i++) + for ( int i = row+1; i < (int)indices.size() && idx1 == 0; i++) //TODO: mismathc signed/unsigned if ( indices[i] == row+1 ) idx1 = i; indices[idx1] = idx; } @@ -681,12 +681,12 @@ std::vector SALOMEDSImpl_AttributeTableOfString::SortByRow(const int theRow } result = indices; - for ( int col = 0; col < indices.size(); col++ ) { + for ( int col = 0; col < (int)indices.size(); col++ ) { //TODO: mismatch signed/unsigned int idx = indices[col]; if ( col+1 == idx ) continue; SwapColumns(col+1, idx); int idx1 = 0; - for ( int i = col+1; i < indices.size() && idx1 == 0; i++) + for ( int i = col+1; i < (int)indices.size() && idx1 == 0; i++) //TODO: mismatch signed/unsigned if ( indices[i] == col+1 ) idx1 = i; indices[idx1] = idx; } @@ -721,12 +721,12 @@ std::vector SALOMEDSImpl_AttributeTableOfString::SortByColumn(const int the } result = indices; - for ( int row = 0; row < indices.size(); row++ ) { + for ( int row = 0; row < (int)indices.size(); row++ ) { //TODO: mismatch signed/unsigned int idx = indices[row]; if ( row+1 == idx ) continue; SwapRows(row+1, idx); int idx1 = 0; - for ( int i = row+1; i < indices.size() && idx1 == 0; i++) + for ( int i = row+1; i < (int)indices.size() && idx1 == 0; i++) //TODO: mismatch signed/unsigned if ( indices[i] == row+1 ) idx1 = i; indices[idx1] = idx; } diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_Callback.hxx b/src/SALOMEDSImpl/SALOMEDSImpl_Callback.hxx index e0cb0ee09..fb2594f5a 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_Callback.hxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_Callback.hxx @@ -57,11 +57,11 @@ public: class SALOMEDSIMPL_EXPORT SALOMEDSImpl_AbstractCallback { public: - virtual bool addSO_Notification(const SALOMEDSImpl_SObject& theSObject){return false;}; - virtual bool removeSO_Notification(const SALOMEDSImpl_SObject& theSObject){return false;}; - virtual bool modifySO_Notification(const SALOMEDSImpl_SObject& theSObject, int reason ){return false;}; - virtual bool modifyNB_Notification(const char* theVarName){return false;}; - virtual void RegisterGenObj (const std::string& theIOR) {} - virtual void UnRegisterGenObj(const std::string& theIOR) {} + virtual bool addSO_Notification(const SALOMEDSImpl_SObject& /*theSObject*/){return false;} + virtual bool removeSO_Notification(const SALOMEDSImpl_SObject& /*theSObject*/){return false;} + virtual bool modifySO_Notification(const SALOMEDSImpl_SObject& /*theSObject*/, int /*reason*/ ){return false;} + virtual bool modifyNB_Notification(const char* /*theVarName*/){return false;} + virtual void RegisterGenObj (const std::string& /*theIOR*/) {} + virtual void UnRegisterGenObj(const std::string& /*theIOR*/) {} }; #endif diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_StudyBuilder.cxx b/src/SALOMEDSImpl/SALOMEDSImpl_StudyBuilder.cxx index d9f9d8cea..6390249c5 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_StudyBuilder.cxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_StudyBuilder.cxx @@ -439,7 +439,7 @@ bool SALOMEDSImpl_StudyBuilder::LoadWith(const SALOMEDSImpl_SComponent& anSCO, * Purpose : */ //============================================================================ -bool SALOMEDSImpl_StudyBuilder::Load(const SALOMEDSImpl_SObject& sco) +bool SALOMEDSImpl_StudyBuilder::Load(const SALOMEDSImpl_SObject& /*sco*/) { _errorCode = "Not implemented"; return false; @@ -802,7 +802,7 @@ int SALOMEDSImpl_StudyBuilder::UndoLimit() * Purpose : */ //============================================================================ -void SALOMEDSImpl_StudyBuilder::UndoLimit(int n) +void SALOMEDSImpl_StudyBuilder::UndoLimit(int /*n*/) { _errorCode = ""; CheckLocked(); diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx b/src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx index c1d030588..39f4f2b24 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx @@ -118,7 +118,7 @@ void SALOMEDSImpl_Tool::RemoveTemporaryFiles(const std::string& theDirectory, //============================================================================ std::string SALOMEDSImpl_Tool::GetNameFromPath(const std::string& thePath) { if (thePath.empty()) return ""; - size_t pos = thePath.rfind('/'); + int pos = (int)thePath.rfind('/'); //TODO: conversion from size_t to int if(pos >= 0) return thePath.substr(pos+1, thePath.size()); pos = thePath.rfind('\\'); if(pos >= 0) return thePath.substr(pos+1, thePath.size()); @@ -140,7 +140,7 @@ std::string SALOMEDSImpl_Tool::GetDirFromPath(const std::string& thePath) { std::string path; if (!thePath.empty()) { - size_t pos = thePath.rfind('/'); + int pos = (int)thePath.rfind('/'); //TODO: conversion from size_t to int if (pos < 0) pos = thePath.rfind('\\'); if (pos < 0) pos = thePath.rfind('|'); @@ -169,7 +169,7 @@ std::vector SALOMEDSImpl_Tool::splitString(const std::string& theVa { std::vector vs; if(theValue[0] == separator && theValue.size() == 1) return vs; - size_t pos = theValue.find(separator); + int pos = (int)theValue.find(separator); //TODO: conversion from size_t to int if(pos < 0) { vs.push_back(theValue); return vs; @@ -197,7 +197,7 @@ std::vector treatRepetation(const std::string& theValue); std::vector treatRepetation(const std::string& theValue) { std::vector aResult; - size_t pos = theValue.find(";*="); + int pos = (int)theValue.find(";*="); //TODO: conversion from size_t to int if(pos < 0 ) { aResult.push_back(theValue); @@ -217,7 +217,7 @@ std::vector SALOMEDSImpl_Tool::splitStringWithEmpty(const std::stri { std::vector aResult; if(theValue[0] == sep ) aResult.push_back(std::string()); - size_t pos = theValue.find(sep); + int pos = (int)theValue.find(sep); //TODO: conversion from size_t to int if(pos < 0 ) { if(sep == '|') { diff --git a/src/SALOMESDS/SALOMESDS_PickelizedPyObjRdOnlyServer.cxx b/src/SALOMESDS/SALOMESDS_PickelizedPyObjRdOnlyServer.cxx index e312e1756..e6fb81b28 100644 --- a/src/SALOMESDS/SALOMESDS_PickelizedPyObjRdOnlyServer.cxx +++ b/src/SALOMESDS/SALOMESDS_PickelizedPyObjRdOnlyServer.cxx @@ -36,7 +36,7 @@ PickelizedPyObjRdOnlyServer::~PickelizedPyObjRdOnlyServer() { } -void PickelizedPyObjRdOnlyServer::addKeyValueErrorIfAlreadyExisting(PyObject *key, PyObject *value) +void PickelizedPyObjRdOnlyServer::addKeyValueErrorIfAlreadyExisting(PyObject * /*key*/, PyObject * /*value*/) { throw Exception("PickelizedPyObjRdOnlyServer::addKeyValueErrorIfAlreadyExisting : incompatible with RdOnly !"); } diff --git a/src/SALOMESDS/SALOMESDS_PickelizedPyObjServer.cxx b/src/SALOMESDS/SALOMESDS_PickelizedPyObjServer.cxx index 7e4fa77c6..83fc25c17 100644 --- a/src/SALOMESDS/SALOMESDS_PickelizedPyObjServer.cxx +++ b/src/SALOMESDS/SALOMESDS_PickelizedPyObjServer.cxx @@ -70,13 +70,13 @@ void PickelizedPyObjServer::checkKeyPresent(PyObject *key) checkKeyPresence(key,true); } -void PickelizedPyObjServer::addKeyValueHard(PyObject *key, PyObject *value) +void PickelizedPyObjServer::addKeyValueHard(PyObject * /*key*/, PyObject * /*value*/) { std::ostringstream oss; oss << "PickelizedPyObjServer::addKeyValueHard : var \"" << getVarNameCpp() << "\" is not permitted to alter its value !"; throw Exception(oss.str()); } -void PickelizedPyObjServer::removeKeyInVarErrorIfNotAlreadyExisting(PyObject *key) +void PickelizedPyObjServer::removeKeyInVarErrorIfNotAlreadyExisting(PyObject * /*key*/) { std::ostringstream oss; oss << "PickelizedPyObjServer::removeKeyInVarErrorIfNotAlreadyExisting : var \"" << getVarNameCpp() << "\" is not permitted to alter its value !"; throw Exception(oss.str()); diff --git a/src/SALOMESDS/SALOMESDS_RefCountServ.cxx b/src/SALOMESDS/SALOMESDS_RefCountServ.cxx index 7a7c72186..5078790bd 100644 --- a/src/SALOMESDS/SALOMESDS_RefCountServ.cxx +++ b/src/SALOMESDS/SALOMESDS_RefCountServ.cxx @@ -43,7 +43,7 @@ RefCountServ::RefCountServ():_cnt(1) { } -RefCountServ::RefCountServ(const RefCountServ& other):_cnt(1) +RefCountServ::RefCountServ(const RefCountServ& /*other*/):_cnt(1) { } diff --git a/src/SALOMESDS/SALOMESDS_Sha1Keeper.cxx b/src/SALOMESDS/SALOMESDS_Sha1Keeper.cxx index 038b1e200..1045578a5 100644 --- a/src/SALOMESDS/SALOMESDS_Sha1Keeper.cxx +++ b/src/SALOMESDS/SALOMESDS_Sha1Keeper.cxx @@ -23,7 +23,7 @@ #include -void SALOMESDS::Sha1Keeper::checkSame(const std::string& varName,const std::string& compareFuncContent, PyObject *oldObj, PyObject *newObj) +void SALOMESDS::Sha1Keeper::checkSame(const std::string& /*varName*/,const std::string& compareFuncContent, PyObject *oldObj, PyObject *newObj) { if(compareFuncContent!=_cmp_func_content) { diff --git a/src/Utils/Test/UtilsTest.cxx b/src/Utils/Test/UtilsTest.cxx index 8fc3c3cf3..1fc1a0c90 100644 --- a/src/Utils/Test/UtilsTest.cxx +++ b/src/Utils/Test/UtilsTest.cxx @@ -90,7 +90,7 @@ UtilsTest::tearDown() int genExcept() { throw SALOME_Exception("a message"); -}; +} // ============================================================================ /*! -- 2.39.2