Support Class Library
A set of tools providing classes and utility
InvalidAnyCast.h
Go to the documentation of this file.
1 #pragma once
2 
4 #include <scl/macros.h>
5 
6 namespace scl{
7  namespace exceptions{
11  class InvalidAnyCast : public InvalidCast{
12  public:
13  using InvalidCast::InvalidCast;
14  realConst(char*) type() const noexcept override{
15  return "scl::exceptions::InvalidAnyCast";
16  }
17 
18  InvalidAnyCast() : InvalidAnyCast("Tried to cast Any to an unsupported type"){
19  }
20  };
21  }
22 }
Global namespace of the SCL.
Definition: alias.hpp:3
const char *const type() const noexcept override
A string describing the name of the exception class.
#define realConst(type)
Definition: macros.h:3
Exception class used when attempting to cast an Any to the wrong type.
Exception class used when a conversion is impossible.
Definition: InvalidCast.h:11