Reduces the usage of noexcept in accordance with a discussion with zeux in the PR 183
This commit is contained in:
parent
f43c2e1959
commit
6eb1beb8f8
@ -7591,7 +7591,7 @@ PUGI__NS_BEGIN
|
||||
_root_size = state._root_size;
|
||||
}
|
||||
|
||||
void release() PUGIXML_NOEXCEPT
|
||||
void release()
|
||||
{
|
||||
xpath_memory_block* cur = _root;
|
||||
assert(cur);
|
||||
@ -8613,13 +8613,13 @@ PUGI__NS_BEGIN
|
||||
}
|
||||
}
|
||||
|
||||
template <typename T> PUGI__FN void delete_xpath_variable(T* var) PUGIXML_NOEXCEPT
|
||||
template <typename T> PUGI__FN void delete_xpath_variable(T* var)
|
||||
{
|
||||
var->~T();
|
||||
xml_memory::deallocate(var);
|
||||
}
|
||||
|
||||
PUGI__FN void delete_xpath_variable(xpath_value_type type, xpath_variable* var) PUGIXML_NOEXCEPT
|
||||
PUGI__FN void delete_xpath_variable(xpath_value_type type, xpath_variable* var)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
@ -11872,7 +11872,7 @@ PUGI__NS_BEGIN
|
||||
return new (memory) xpath_query_impl();
|
||||
}
|
||||
|
||||
static void destroy(xpath_query_impl* impl) PUGIXML_NOEXCEPT
|
||||
static void destroy(xpath_query_impl* impl)
|
||||
{
|
||||
// free all allocated pages
|
||||
impl->alloc.release();
|
||||
@ -12368,7 +12368,7 @@ namespace pugi
|
||||
return true;
|
||||
}
|
||||
|
||||
PUGI__FN void xpath_variable_set::_destroy(xpath_variable* var) PUGIXML_NOEXCEPT
|
||||
PUGI__FN void xpath_variable_set::_destroy(xpath_variable* var)
|
||||
{
|
||||
while (var)
|
||||
{
|
||||
|
||||
@ -82,15 +82,18 @@
|
||||
#endif
|
||||
|
||||
// If C++ is 2011 or higher, add 'noexcept' specifiers
|
||||
#ifndef PUGIXML_NOEXCEPT
|
||||
#ifndef PUGIXML_HAS_NOEXCEPT
|
||||
# if __cplusplus >= 201103
|
||||
# define PUGIXML_NOEXCEPT noexcept
|
||||
# define PUGIXML_HAS_NOEXCEPT
|
||||
# elif defined(_MSC_FULL_VER) && _MSC_FULL_VER >= 190023026
|
||||
# define PUGIXML_NOEXCEPT noexcept
|
||||
# else
|
||||
# define PUGIXML_NOEXCEPT
|
||||
# define PUGIXML_HAS_NOEXCEPT
|
||||
# endif
|
||||
#endif
|
||||
#ifdef PUGIXML_HAS_NOEXCEPT
|
||||
# define PUGIXML_NOEXCEPT noexcept
|
||||
#else
|
||||
# define PUGIXML_NOEXCEPT
|
||||
#endif
|
||||
|
||||
// If C++ is 2011 or higher, add 'override' qualifiers
|
||||
#ifndef PUGIXML_OVERRIDE
|
||||
@ -1136,7 +1139,7 @@ namespace pugi
|
||||
xpath_variable* _find(const char_t* name) const;
|
||||
|
||||
static bool _clone(xpath_variable* var, xpath_variable** out_result);
|
||||
static void _destroy(xpath_variable* var) PUGIXML_NOEXCEPT;
|
||||
static void _destroy(xpath_variable* var);
|
||||
|
||||
public:
|
||||
// Default constructor/destructor
|
||||
|
||||
Loading…
Reference in New Issue
Block a user