File: doxygen.h

package info (click to toggle)
freespace2 24.2.0%2Brepack-1
  • links: PTS, VCS
  • area: non-free
  • in suites: forky, sid
  • size: 43,716 kB
  • sloc: cpp: 595,001; ansic: 21,741; python: 1,174; sh: 457; makefile: 248; xml: 181
file content (85 lines) | stat: -rw-r--r-- 2,436 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
/*
 * Copyright (C) Volition, Inc. 1999.  All rights reserved.
 *
 * All source code herein is the property of Volition, Inc. You may not sell
 * or otherwise commercially exploit the source or things you created based on
 * the source.
 */

#if defined(DOXYGEN)
/**
 * @file
 *
 * @brief Macros to abstract compiler capabilities (for doxygen use only)
 */

/**
 * @brief Identifies a printf-style format string
 */
#define SCP_FORMAT_STRING

/**
 * @brief Specify which arguments are involved in printf-style string formatting
 *
 * @details Expands to a compiler specific attribute which specify where the
 *          format arguments are located. Parameters are 1-based which also
 *          includes the 'this' parameter at position 1 for class methods.
 *
 * @param formatArg Location of format string argument in the argument list
 * @param varArgs Location where the variable arguments begin
 */
#define SCP_FORMAT_STRING_ARGS(formatArg,varArgs)

/**
 * @brief Format specifier for a @c size_t argument
 *
 * Due to different runtimes using different format specifier for these types
 * it's necessary to hide these changes behind a macro. Use this in place of %zu
 */
#define SIZE_T_ARG    "%zu"

/**
 * @brief Format specifier for a @c ptrdiff_t argument
 *
 * Due to different runtimes using different format specifier for these types
 * it's necessary to hide these changes behind a macro. Use this in place of %zd
 */
#define PTRDIFF_T_ARG "%zd"

/**
 * @brief Attribute for forcing a static variable to be instantiated
 *
 * This can be used to ensure that a static variable is present even if it isn't referenced in the translation unit
 */
#define USED_VARIABLE

/**
 * @brief For use in a case statement which falls through
 *
 * Some compilers issue a warning if a fallthrough is detected. This define can be used to suppress that warning.
 */
#define FALLTHROUGH

/**
 * @brief Specifies that an analyzer should consider this function as no-return
 */
#define CLANG_ANALYZER_NORETURN

/**
 * @brief Specifies that the code at which point this macro appears at is unreachable
 * @param msg The message to display in debug mode
 * @param ... Format arguments for the message
 */
#define UNREACHABLE(msg, ...)

/**
 * @brief Suppresses all warnings and allows to pop back to normal afterwards
 */
#define PUSH_SUPPRESS_WARNINGS

/**
 * @brief Restored previous warning settings
 */
#define POP_SUPPRESS_WARNINGS

#endif