Skip to content
Snippets Groups Projects
Commit ed2bf03a authored by Jan Travnicek's avatar Jan Travnicek Committed by Jan Trávníček
Browse files

add some missing noexcepts

parent efe3651b
No related branches found
No related tags found
1 merge request!95Many clang-tidy fixes
...@@ -46,7 +46,7 @@ public: ...@@ -46,7 +46,7 @@ public:
AbstractRegister ( ReturnType ( * callback ) ( ParameterTypes ... ), ParamNames ... paramNames ) : AbstractRegister ( callback, abstraction::AlgorithmCategories::AlgorithmCategory::DEFAULT, paramNames ... ) { AbstractRegister ( ReturnType ( * callback ) ( ParameterTypes ... ), ParamNames ... paramNames ) : AbstractRegister ( callback, abstraction::AlgorithmCategories::AlgorithmCategory::DEFAULT, paramNames ... ) {
} }
   
AbstractRegister ( AbstractRegister && ) = default; AbstractRegister ( AbstractRegister && ) noexcept = default;
   
AbstractRegister && setDocumentation ( std::string documentation ) && { AbstractRegister && setDocumentation ( std::string documentation ) && {
abstraction::AlgorithmRegistry::setDocumentationOfAlgorithm < Algorithm, ParameterTypes ... > ( m_category, std::move ( documentation ) ); abstraction::AlgorithmRegistry::setDocumentationOfAlgorithm < Algorithm, ParameterTypes ... > ( m_category, std::move ( documentation ) );
...@@ -67,7 +67,7 @@ public: ...@@ -67,7 +67,7 @@ public:
} ) { } ) {
} }
   
WrapperRegister ( WrapperRegister && ) = default; WrapperRegister ( WrapperRegister && ) noexcept = default;
   
WrapperRegister && setDocumentation ( std::string documentation ) && { WrapperRegister && setDocumentation ( std::string documentation ) && {
abstraction::AlgorithmRegistry::setDocumentationOfWrapper < Algorithm, ParameterTypes ... > ( std::move ( documentation ) ); abstraction::AlgorithmRegistry::setDocumentationOfWrapper < Algorithm, ParameterTypes ... > ( std::move ( documentation ) );
...@@ -92,7 +92,7 @@ public: ...@@ -92,7 +92,7 @@ public:
} ), m_methodName ( methodName ) { } ), m_methodName ( methodName ) {
} }
   
MethodRegister ( MethodRegister && ) = default; MethodRegister ( MethodRegister && ) noexcept = default;
   
MethodRegister && setDocumentation ( std::string documentation ) && { MethodRegister && setDocumentation ( std::string documentation ) && {
abstraction::AlgorithmRegistry::setDocumentationOfMethod < Algorithm, ObjectType, ParameterTypes ... > ( m_methodName, std::move ( documentation ) ); abstraction::AlgorithmRegistry::setDocumentationOfMethod < Algorithm, ObjectType, ParameterTypes ... > ( m_methodName, std::move ( documentation ) );
......
...@@ -98,7 +98,7 @@ public: ...@@ -98,7 +98,7 @@ public:
* *
* \param other the other instance * \param other the other instance
*/ */
ptr_value ( ptr_value && other ) : m_data ( other.m_data ) { ptr_value ( ptr_value && other ) noexcept : m_data ( other.m_data ) {
other.m_data = nullptr; other.m_data = nullptr;
}; };
   
...@@ -123,7 +123,7 @@ public: ...@@ -123,7 +123,7 @@ public:
* *
* \param other the other instance. * \param other the other instance.
*/ */
ptr_value & operator = ( ptr_value && other ) { ptr_value & operator = ( ptr_value && other ) noexcept {
using std::swap; using std::swap;
   
swap ( m_data, other.m_data ); swap ( m_data, other.m_data );
...@@ -135,7 +135,7 @@ public: ...@@ -135,7 +135,7 @@ public:
* \brief * \brief
* Destructor will free the owned instance. * Destructor will free the owned instance.
*/ */
~ptr_value ( ) { ~ptr_value ( ) noexcept {
delete m_data; delete m_data;
} }
   
......
...@@ -45,7 +45,7 @@ public: ...@@ -45,7 +45,7 @@ public:
   
Register ( const Register & ) = delete; Register ( const Register & ) = delete;
   
Register ( Register && other ) : data ( std::move ( other.data ) ), m_finish ( other.m_finish ) { Register ( Register && other ) noexcept : data ( std::move ( other.data ) ), m_finish ( other.m_finish ) {
other.m_finish = [] ( T ) { }; other.m_finish = [] ( T ) { };
} }
   
...@@ -73,7 +73,7 @@ public: ...@@ -73,7 +73,7 @@ public:
   
Register ( const Register & ) = delete; Register ( const Register & ) = delete;
   
Register ( Register && other ) : m_finish ( other.m_finish ) { Register ( Register && other ) noexcept : m_finish ( other.m_finish ) {
other.m_finish = [] ( ) { }; other.m_finish = [] ( ) { };
} }
   
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment