bux API Reference
1.9.0
Static library of whatever are seen required in general purpose but not directly supported from Modern C++. Or whatever reusable originated from my side projects.
Loading...
Searching...
No Matches
include
bux
XException.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
XPlatform.h
"
// CUR_FUNC_
4
#include <format>
// std::format()
5
#include <stdexcept>
// std::runtime_error, std::logic_error
6
7
namespace
bux
{
8
9
//
10
// Externals
11
//
12
#ifdef _WIN32
17
void
catchSE(
bool
useOldHookFirst =
true
);
18
#endif
19
20
}
// namespace bux
21
22
#define THROW_AS(exp_class,fmtStr,...) \
23
throw exp_class(std::format(__FILE__ "(" __DATE__ ")#{} {}: " fmtStr, __LINE__, CUR_FUNC_, ##__VA_ARGS__))
24
#define RAW_THROW_AS(exp_class,fmtStr,...) \
25
throw exp_class(std::format(fmtStr, ##__VA_ARGS__))
26
#define THROW_CLASS(exp_class) \
27
throw exp_class(std::format(__FILE__ "(" __DATE__ ")#{} {}: ", __LINE__, CUR_FUNC_))
28
29
#define LOGIC_ERROR(fmtStr,...) THROW_AS(std::logic_error, fmtStr, ##__VA_ARGS__)
31
#define RUNTIME_ERROR(fmtStr,...) THROW_AS(std::runtime_error, fmtStr, ##__VA_ARGS__)
33
34
#define RAW_LOGIC_ERROR(fmtStr,...) RAW_THROW_AS(std::logic_error, fmtStr, ##__VA_ARGS__)
35
#define RAW_RUNTIME_ERROR(fmtStr,...) RAW_THROW_AS(std::runtime_error, fmtStr, ##__VA_ARGS__)
XPlatform.h
bux
THE common namespace of bux library.
Definition
AtomiX.cpp:3
Generated by
1.12.0