Merge pull request #1191 from georgthegreat/noexcept

Modernize noexcept specifications
This commit is contained in:
Vissarion Fisikopoulos 2023-09-08 12:59:01 +03:00 committed by GitHub
commit 92c7462a8c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
14 changed files with 18 additions and 26 deletions

View File

@ -91,7 +91,7 @@ public:
\brief Returns the explanatory string.
\return Pointer to a null-terminated string with explanatory information.
*/
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Boost.Geometry Centroid calculation exception";
}

View File

@ -53,7 +53,7 @@ public:
inline overlay_invalid_input_exception() {}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Boost.Geometry Overlay invalid input exception";
}

View File

@ -46,10 +46,7 @@ public:
message += method;
}
virtual ~turn_info_exception() throw()
{}
virtual char const* what() const throw()
virtual char const* What() const noexcept
{
return message.c_str();
}

View File

@ -22,10 +22,7 @@ public:
inline inconsistent_turns_exception() {}
virtual ~inconsistent_turns_exception() throw()
{}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Boost.Geometry Inconsistent Turns exception";
}

View File

@ -33,7 +33,7 @@ namespace boost { namespace geometry
class exception : public std::exception
{
public:
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Boost.Geometry exception";
}
@ -52,7 +52,7 @@ public:
inline invalid_input_exception() {}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Boost.Geometry Invalid-Input exception";
}
@ -77,7 +77,7 @@ public:
inline empty_input_exception() {}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Boost.Geometry Empty-Input exception";
}
@ -96,7 +96,7 @@ public:
inline invalid_output_exception() {}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Boost.Geometry Invalid-Output exception";
}

View File

@ -52,7 +52,7 @@ public:
: m_msg(msg)
{}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
//return "Shapefile read error";
return m_msg.what();

View File

@ -32,7 +32,7 @@ public:
: m_filename(filename)
{}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return m_filename.c_str();
}

View File

@ -49,7 +49,7 @@ public:
inline read_wkb_exception() {}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Boost.Geometry Read WKB exception";
}

View File

@ -96,9 +96,7 @@ struct read_wkt_exception : public geometry::exception
complete = message + "' in (" + wkt.substr(0, 100) + ")";
}
virtual ~read_wkt_exception() throw() {}
virtual const char* what() const throw()
virtual const char* what() const noexcept
{
return complete.c_str();
}

View File

@ -43,7 +43,7 @@ public:
, m_msg(msg)
{}
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
//return "Boost.Geometry Projection exception";
return m_msg.what();

View File

@ -21,7 +21,7 @@ namespace boost { namespace geometry
class bad_str_cast : public geometry::exception
{
virtual char const* what() const throw()
virtual char const* what() const noexcept
{
return "Unable to convert from string.";
}

View File

@ -15,7 +15,7 @@
struct throwing_value_copy_exception : public std::exception
{
const char * what() const throw() { return "value copy failed."; }
const char * what() const noexcept { return "value copy failed."; }
};
struct throwing_value
@ -79,7 +79,7 @@ struct value< std::pair<bg::model::point<T, 2, C>, throwing_value> >
struct throwing_varray_exception : public std::exception
{
const char * what() const throw() { return "static vector exception."; }
const char * what() const noexcept { return "static vector exception."; }
};
struct throwing_varray_settings

View File

@ -250,7 +250,7 @@ public:
struct node_bad_alloc : public std::exception
{
const char * what() const throw() { return "internal node creation failed."; }
const char * what() const noexcept { return "internal node creation failed."; }
};
struct throwing_node_settings

View File

@ -20,7 +20,7 @@
struct assert_failure_exception
: std::exception
{
const char * what() const throw()
const char * what() const noexcept
{
return "assertion failure";
}