Expression Templates Library (ETL)
diagonal_exception.hpp
Go to the documentation of this file.
1 //=======================================================================
2 // Copyright (c) 2014-2023 Baptiste Wicht
3 // Distributed under the terms of the MIT License.
4 // (See accompanying file LICENSE or copy at
5 // http://opensource.org/licenses/MIT)
6 //=======================================================================
7 
13 #pragma once
14 
15 #include <exception>
16 
17 namespace etl {
18 
23 struct diagonal_exception : std::exception {
27  const char* what() const noexcept override {
28  return "Invalid assignment to a diagonal matrix";
29  }
30 };
31 
32 } //end of namespace etl
Exception that is thrown when an operation is made to a diagonal matrix that would render it non-diag...
Definition: diagonal_exception.hpp:23
Root namespace for the ETL library.
Definition: adapter.hpp:15
const char * what() const noexcept override
Returns a description of the exception.
Definition: diagonal_exception.hpp:27