Skip to content
This repository has been archived by the owner on Jul 8, 2022. It is now read-only.

Commit

Permalink
Fix build errors when using C++17 (#405)
Browse files Browse the repository at this point in the history
Removed dynamic exception specifications
  • Loading branch information
abogani authored and bourtemb committed Nov 8, 2017
1 parent 277d988 commit 432dcc4
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 34 deletions.
3 changes: 1 addition & 2 deletions include/log4tango/Level.hh
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,7 @@ public:
* @throw std::invalid_argument if the level_name does not
* correspond with a known Level name or a number
**/
static Value get_value (const std::string& level_name)
throw(std::invalid_argument);
static Value get_value (const std::string& level_name);
};

} // namespace log4tango
Expand Down
19 changes: 0 additions & 19 deletions include/tango/client/helpers/DeviceProxyHelper.h
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,6 @@ namespace Tango
// client_device : Reference to the client device (for logging purpose).
//---------------------------------------------------------------------------
HelperBase (const std::string& device_name, Tango::DeviceImpl *client_device = 0)
throw (Tango::DevFailed)
: Tango::LogAdapter(client_device), device_proxy_(0)
{
_DEV_TRY_REACTION
Expand Down Expand Up @@ -292,7 +291,6 @@ namespace Tango
void internal_command (const std::string& cmd_name,
std::string file,
int line)
throw (Tango::DevFailed)
{
if (device_proxy_)
{
Expand Down Expand Up @@ -332,7 +330,6 @@ namespace Tango

template <class _IN, class _OUT>
void internal_command_inout (const std::string& cmd_name, const _IN& argin, _OUT& argout, std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
if (device_proxy_)
{
Expand Down Expand Up @@ -388,7 +385,6 @@ namespace Tango
std::vector<std::string>& _sv_out,
std::string file= __FILE__,
int line= __LINE__)
throw (Tango::DevFailed)
{

if (device_proxy_)
Expand Down Expand Up @@ -429,7 +425,6 @@ namespace Tango
//---------------------------------------------------------------------------
template <class _IN>
void internal_command_inout (const std::string& cmd_name, const _IN& argin, DevVarDoubleStringArray* argout,std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
#if (defined(_MSC_VER) && _MSC_VER < 1300)
#pragma message (" TANGO WARNING ***** command_inout:Use only STL vector instead of DevVarDoubleStringArray *****")
Expand All @@ -447,7 +442,6 @@ namespace Tango
//---------------------------------------------------------------------------
template <class _IN>
void internal_command_inout (const std::string& cmd_name, const _IN& argin, DevVarLongStringArray* argout,std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
#if (defined(_MSC_VER) && _MSC_VER < 1300)
#pragma message (" TANGO WARNING ***** command_inout:Use only STL vector instead of DevVarLongStringArray *****")
Expand All @@ -464,7 +458,6 @@ namespace Tango
//---------------------------------------------------------------------------
template <class _IN>
void internal_command_inout (const std::string& cmd_name, const _IN& argin, DevVarDoubleStringArray& argout,std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
#if (defined(_MSC_VER) && _MSC_VER < 1300)
#pragma message (" TANGO WARNING ***** command_inout:Use only STL vector instead of DevVarDoubleStringArray *****")
Expand All @@ -482,7 +475,6 @@ namespace Tango
//---------------------------------------------------------------------------
template <class _IN>
void internal_command_inout (const std::string& cmd_name, const _IN& argin, DevVarLongStringArray& argout,std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
#if (defined(_MSC_VER) && _MSC_VER < 1300)
#pragma message (" TANGO WARNING ***** command_inout:Use only STL vector instead of DevVarLongStringArray *****")
Expand Down Expand Up @@ -510,7 +502,6 @@ namespace Tango
#endif
template <class _IN>
void internal_command_in (const std::string& cmd_name, const _IN& argin, std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
if (device_proxy_)
{
Expand Down Expand Up @@ -548,7 +539,6 @@ namespace Tango
void internal_command_in (const std::string& cmd_name,
const std::vector<_IN>& _nv_in,
const std::vector<std::string>& _sv_in, std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
if (device_proxy_)
{
Expand Down Expand Up @@ -585,7 +575,6 @@ namespace Tango
#endif
template <class _OUT>
void internal_command_out (const std::string& cmd_name, _OUT& argout, std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{

if (device_proxy_)
Expand Down Expand Up @@ -624,7 +613,6 @@ namespace Tango
//---------------------------------------------------------------------------
template <class _OUT>
void internal_command_out(_OUT dummy, DevVarDoubleStringArray* argout, std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
#if (defined(_MSC_VER) && _MSC_VER < 1300)
#pragma message (" TANGO WARNING ***** command_out:Use only STL vector instead of DevVarDoubleStringArray *****")
Expand All @@ -643,7 +631,6 @@ namespace Tango
//---------------------------------------------------------------------------
template <class _OUT>
void internal_command_out (_OUT dummy, DevVarLongStringArray* argout, std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
#if (defined(_MSC_VER) && _MSC_VER < 1300)
#pragma message (" TANGO WARNING ***** command_out:Use only STL vector instead of DevVarLongStringArray *****")
Expand All @@ -660,7 +647,6 @@ namespace Tango
//---------------------------------------------------------------------------
template <class _OUT>
void internal_command_out(_OUT dummy, DevVarDoubleStringArray& argout, std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
#if (defined(_MSC_VER) && _MSC_VER < 1300)
#pragma message (" TANGO WARNING ***** command_out:Use only STL vector instead of DevVarDoubleStringArray *****")
Expand All @@ -677,7 +663,6 @@ namespace Tango
//---------------------------------------------------------------------------
template <class _OUT>
void internal_command_out (_OUT dummy, DevVarLongStringArray& argout, std::string file= __FILE__, int line= __LINE__)
throw (Tango::DevFailed)
{
#if (defined(_MSC_VER) && _MSC_VER < 1300)
#pragma message (" TANGO WARNING ***** command_out:Use only STL vector instead of DevVarLongStringArray *****")
Expand Down Expand Up @@ -707,7 +692,6 @@ namespace Tango
std::vector<std::string>& _sv_out,
std::string file= __FILE__,
int line= __LINE__)
throw (Tango::DevFailed)
{
if (device_proxy_)
{
Expand Down Expand Up @@ -787,7 +771,6 @@ class AttributeHelper : public virtual HelperBase
//---------------------------------------------------------------------------
template <class _VAL>
void internal_write_attribute (const std::string& attr_name, const _VAL& attr_value, std::string file, int line)
throw (Tango::DevFailed)
{
if (device_proxy_)
{
Expand Down Expand Up @@ -817,7 +800,6 @@ class AttributeHelper : public virtual HelperBase
//---------------------------------------------------------------------------
template <class _VAL>
void internal_read_attribute (const std::string& attr_name, _VAL& attr_value, std::string file, int line )
throw (Tango::DevFailed)
{

if (device_proxy_)
Expand Down Expand Up @@ -860,7 +842,6 @@ class AttributeHelper : public virtual HelperBase
//---------------------------------------------------------------------------
template <class _VAL>
void internal_read_attribute_w (const std::string& attr_name, _VAL& w_attr_value, std::string file, int line )
throw (Tango::DevFailed)
{

if (device_proxy_)
Expand Down
9 changes: 3 additions & 6 deletions include/tango/server/device_2.h
Original file line number Diff line number Diff line change
Expand Up @@ -256,8 +256,7 @@ class Device_2Impl : public virtual POA_Tango::Device_2,
* Click <a href="../../../tango_idl/idl_html/_Tango.html#DevFailed">here</a> to read
* <b>DevFailed</b> exception specification
*/
virtual Tango::AttributeConfigList_2 *get_attribute_config_2(const Tango::DevVarStringArray& names)
throw(Tango::DevFailed, CORBA::SystemException);
virtual Tango::AttributeConfigList_2 *get_attribute_config_2(const Tango::DevVarStringArray& names);


/**
Expand All @@ -281,8 +280,7 @@ class Device_2Impl : public virtual POA_Tango::Device_2,
* <b>DevFailed</b> exception specification
*/
virtual Tango::DevAttrHistoryList *read_attribute_history_2(const char* name,
DevLong n)
throw(Tango::DevFailed, CORBA::SystemException);
DevLong n);

/**
* Read command value history.
Expand All @@ -307,8 +305,7 @@ class Device_2Impl : public virtual POA_Tango::Device_2,
*/

virtual Tango::DevCmdHistoryList *command_inout_history_2(const char* command,
DevLong n)
throw(Tango::DevFailed, CORBA::SystemException);
DevLong n);
//@}

private:
Expand Down
1 change: 0 additions & 1 deletion src/log4tango/Level.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ static const std::string names[NUM_LEVELS] = {
}

Level::Value Level::get_value(const std::string& level_name)
throw(std::invalid_argument)
{
static const std::string names[NUM_LEVELS] = {
std::string("OFF"),
Expand Down
9 changes: 3 additions & 6 deletions src/server/device_2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1108,8 +1108,7 @@ namespace Tango {
//
//--------------------------------------------------------------------------

Tango::AttributeConfigList_2 *Device_2Impl::get_attribute_config_2(const Tango::DevVarStringArray &names)
throw(Tango::DevFailed, CORBA::SystemException) {
Tango::AttributeConfigList_2 *Device_2Impl::get_attribute_config_2(const Tango::DevVarStringArray &names) {
TangoMonitor &mon = get_att_conf_monitor();
AutoTangoMonitor sync(&mon);

Expand Down Expand Up @@ -1212,8 +1211,7 @@ namespace Tango {
//--------------------------------------------------------------------------

Tango::DevCmdHistoryList *Device_2Impl::command_inout_history_2(const char *command,
DevLong n)
throw(Tango::DevFailed, CORBA::SystemException) {
DevLong n) {
TangoMonitor &mon = get_poll_monitor();
AutoTangoMonitor sync(&mon);

Expand Down Expand Up @@ -1386,8 +1384,7 @@ namespace Tango {
//--------------------------------------------------------------------------

Tango::DevAttrHistoryList *Device_2Impl::read_attribute_history_2(const char *name,
DevLong n)
throw(Tango::DevFailed, CORBA::SystemException) {
DevLong n) {
TangoMonitor &mon = get_poll_monitor();
AutoTangoMonitor sync(&mon);

Expand Down

0 comments on commit 432dcc4

Please sign in to comment.