clang-tidy: override
[alexxy/gromacs.git] / src / gromacs / utility / exceptions.h
index 9ba4cd6e4ea1a08f674175a7148edda145a70038..42d4fbfcb24095154af81521d8edf2e66518f246 100644 (file)
@@ -264,7 +264,7 @@ class GromacsException : public std::exception
     public:
         // Explicitly declared because some compiler/library combinations warn
         // about missing noexcept otherwise.
-        virtual ~GromacsException() noexcept {}
+        ~GromacsException() noexcept override {}
 
         GMX_DEFAULT_CONSTRUCTORS(GromacsException);
 
@@ -273,7 +273,7 @@ class GromacsException : public std::exception
          *
          * The return value is the string that was passed to the constructor.
          */
-        virtual const char *what() const noexcept;
+        const char *what() const noexcept override;
         /*! \brief
          * Returns the error code corresponding to the exception type.
          */
@@ -417,7 +417,7 @@ class FileIOError : public GromacsException
         explicit FileIOError(const ExceptionInitializer &details)
             : GromacsException(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief
@@ -448,7 +448,7 @@ class InvalidInputError : public UserInputError
         explicit InvalidInputError(const ExceptionInitializer &details)
             : UserInputError(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief
@@ -463,7 +463,7 @@ class InconsistentInputError : public UserInputError
         explicit InconsistentInputError(const ExceptionInitializer &details)
             : UserInputError(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief
@@ -487,7 +487,7 @@ class ToleranceError : public GromacsException
         explicit ToleranceError(const ExceptionInitializer &details)
             : GromacsException(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief
@@ -502,7 +502,7 @@ class SimulationInstabilityError : public GromacsException
         explicit SimulationInstabilityError(const ExceptionInitializer &details)
             : GromacsException(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief
@@ -517,7 +517,7 @@ class InternalError : public GromacsException
         explicit InternalError(const ExceptionInitializer &details)
             : GromacsException(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief
@@ -532,7 +532,7 @@ class APIError : public GromacsException
         explicit APIError(const ExceptionInitializer &details)
             : GromacsException(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief
@@ -547,7 +547,7 @@ class RangeError : public GromacsException
         explicit RangeError(const ExceptionInitializer &details)
             : GromacsException(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief
@@ -562,7 +562,7 @@ class NotImplementedError : public APIError
         explicit NotImplementedError(const ExceptionInitializer &details)
             : APIError(details) {}
 
-        virtual int errorCode() const;
+        int errorCode() const override;
 };
 
 /*! \brief