-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathconfig.hpp.in
67 lines (55 loc) · 2.21 KB
/
config.hpp.in
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
// Copyright (C) 2014-2015 Jonathan Müller <[email protected]>
// This file is subject to the license terms in the LICENSE file
// found in the top-level directory of this distribution.
//=== version ===//
/// \brief Major version.
#define FOONATHAN_STRING_ID_VERSION_MAJOR ${version_major}
/// \brief Minor version.
#define FOONATHAN_STRING_ID_VERSION_MINOR ${version_minor}
/// \brief Total version number.
#define FOONATHAN_STRING_ID_VERSION (${version_major} * 100 + ${version_minor})
//=== database ===//
/// \brief Whether or not the database for string ids is active.
/// \detail This is \c true by default, change it via CMake option \c FOONATHAN_STRING_ID_DATABASE.
#cmakedefine01 FOONATHAN_STRING_ID_DATABASE
/// \brief Whether or not the database should thread safe.
/// \detail This is \c true by default, change it via CMake option \c FOONATHAN_STRING_ID_MULTITHREADED.
#cmakedefine01 FOONATHAN_STRING_ID_MULTITHREADED
//=== compatibility ===//
#cmakedefine01 FOONATHAN_IMPL_HAS_NOEXCEPT
#cmakedefine01 FOONATHAN_IMPL_HAS_CONSTEXPR
#cmakedefine01 FOONATHAN_IMPL_HAS_LITERAL
#cmakedefine01 FOONATHAN_IMPL_HAS_OVERRIDE
#ifndef FOONATHAN_NOEXCEPT
#if FOONATHAN_IMPL_HAS_NOEXCEPT
#define FOONATHAN_NOEXCEPT noexcept
#else
#define FOONATHAN_NOEXCEPT
#endif
#endif
#ifndef FOONATHAN_CONSTEXPR
#if FOONATHAN_IMPL_HAS_CONSTEXPR
#define FOONATHAN_CONSTEXPR constexpr
#else
#define FOONATHAN_CONSTEXPR const
#endif
#endif
#ifndef FOONATHAN_CONSTEXPR_FNC
#if FOONATHAN_IMPL_HAS_CONSTEXPR
#define FOONATHAN_CONSTEXPR_FNC constexpr
#else
#define FOONATHAN_CONSTEXPR_FNC inline
#endif
#endif
#ifndef FOONATHAN_OVERRIDE
#if FOONATHAN_IMPL_HAS_OVERRIDE
#define FOONATHAN_OVERRIDE override
#else
#define FOONATHAN_OVERRIDE
#endif
#endif
/// \brief Whether or not the \c constexpr literal operators are availble.
/// \detail If this is \c false, there is only the \ref id() function which can't be used inside switch cases.
#define FOONATHAN_STRING_ID_HAS_LITERAL (FOONATHAN_IMPL_HAS_LITERAL && FOONATHAN_IMPL_HAS_CONSTEXPR)
/// \brief Whether or not the handler functions are atomic.
#cmakedefine01 FOONATHAN_STRING_ID_ATOMIC_HANDLER