sandbox
Loading...
Searching...
No Matches
exception.hpp
1#ifndef LIBSBX_UTILITY_EXCEPTION_HPP_
2#define LIBSBX_UTILITY_EXCEPTION_HPP_
3
4#include <concepts>
5#include <string_view>
6#include <source_location>
7#include <iostream>
8#include <exception>
9#include <stdexcept>
10
11#include <fmt/format.h>
12
13#include <libsbx/utility/target.hpp>
14
15namespace sbx::utility {
16
17struct runtime_error : public std::runtime_error {
18
19 template<typename... Args>
20 runtime_error(fmt::format_string<Args...> fmt, Args&&... args)
21 : std::runtime_error{fmt::format(fmt, std::forward<Args>(args)...)} { }
22
23}; // struct runtime_error
24
25} // namespace sbx::utility
26
27#endif // LIBSBX_UTILITY_EXCEPTION_HPP_
Definition: exception.hpp:17