Project SkyFire Core
SkyFire 5.4.8 server core API documentation
Toggle main menu visibility
Loading...
Searching...
No Matches
Errors.h
Go to the documentation of this file.
1
/*
2
* This file is part of Project SkyFire https://www.projectskyfire.org.
3
* See LICENSE.md file for Copyright information
4
*/
5
6
#ifndef SKYFIRESERVER_ERRORS_H
7
#define SKYFIRESERVER_ERRORS_H
8
9
#include "
Define.h
"
10
11
namespace
Skyfire
12
{
13
14
DECLSPEC_NORETURN
void
Assert
(
char
const
* file,
int
line,
char
const
* function,
char
const
* message)
ATTR_NORETURN
;
15
16
DECLSPEC_NORETURN
void
Fatal
(
char
const
* file,
int
line,
char
const
* function,
char
const
* message)
ATTR_NORETURN
;
17
18
DECLSPEC_NORETURN
void
Error
(
char
const
* file,
int
line,
char
const
* function,
char
const
* message)
ATTR_NORETURN
;
19
20
void
Warning
(
char
const
* file,
int
line,
char
const
* function,
char
const
* message);
21
22
}
// namespace Skyfire
23
24
#define WPAssert(cond, ...) do { if (!(cond)) Skyfire::Assert(__FILE__, __LINE__, __FUNCTION__, #cond); } while (0)
25
#define WPFatal(cond, msg) do { if (!(cond)) Skyfire::Fatal(__FILE__, __LINE__, __FUNCTION__, (msg)); } while (0)
26
#define WPError(cond, msg) do { if (!(cond)) Skyfire::Error(__FILE__, __LINE__, __FUNCTION__, (msg)); } while (0)
27
#define WPWarning(cond, msg) do { if (!(cond)) Skyfire::Warning(__FILE__, __LINE__, __FUNCTION__, (msg)); } while (0)
28
29
#define ASSERT WPAssert
30
31
#endif
Define.h
ATTR_NORETURN
#define ATTR_NORETURN
COREDEBUG.
Definition
Define.h:54
DECLSPEC_NORETURN
#define DECLSPEC_NORETURN
Definition
Define.h:36
Skyfire
Definition
AuthPatchTransfer.h:12
Skyfire::Assert
void Assert(char const *file, int line, char const *function, char const *message)
Definition
Errors.cpp:13
Skyfire::Error
void Error(char const *file, int line, char const *function, char const *message)
Definition
Errors.cpp:30
Skyfire::Fatal
void Fatal(char const *file, int line, char const *function, char const *message)
Definition
Errors.cpp:21
Skyfire::Warning
void Warning(char const *file, int line, char const *function, char const *message)
Definition
Errors.cpp:38
src
server
shared
Debugging
Errors.h
Generated on
for Project SkyFire Core by
1.17.0