HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
exception.hpp
1// Copyright Take Vos 2020-2021.
2// Distributed under the Boost Software License, Version 1.0.
3// (See accompanying file LICENSE_1_0.txt or copy at https://www.boost.org/LICENSE_1_0.txt)
4
5#include "utility.hpp"
6#include <exception>
7#include <stdexcept>
8#include <atomic>
9
10#pragma once
11
12namespace hi {
13inline namespace v1 {
14
18
19
27#define hi_set_terminate_message(msg) \
28 ::hi::terminate_message.store(__FILE__ ":" hi_stringify(__LINE__) ":" msg, std::memory_order::relaxed)
29
35
42[[noreturn]] void terminate_handler() noexcept;
43
44
58class parse_error : public std::runtime_error {
59public:
61};
62
74
83public:
85};
86
94public:
96};
97
99public:
101};
102
104public:
106};
107
109public:
111};
112
113class uri_error : public parse_error {
114public:
115 using parse_error::parse_error;
116};
117
123public:
125};
126
127}} // namespace hi::inline v1
Utilities used by the HikoGUI library itself.
STL namespace.
DOXYGEN BUG.
Definition algorithm.hpp:15
The HikoGUI namespace.
Definition ascii.hpp:19
std::terminate_handler old_terminate_handler
The old terminate handler.
Definition exception.hpp:34
std::atomic< char const * > terminate_message
Message to show when the application is terminated.
Definition exception.hpp:17
void terminate_handler() noexcept
The HikoGUI terminate handler.
Exception thrown during parsing on an error.
Definition exception.hpp:58
Exception thrown during execution of a dynamic operation.
Definition exception.hpp:70
Exception thrown during I/O on an error.
Definition exception.hpp:82
Exception thrown during an operating system call.
Definition exception.hpp:93
Definition exception.hpp:98
Definition exception.hpp:103
Definition exception.hpp:108
Definition exception.hpp:113
Cancel error is caused by user pressing cancel.
Definition exception.hpp:122
T runtime_error(T... args)