algotradelib 0.0.0.9000
C++ header-only library for algorithmic trading
Loading...
Searching...
No Matches
version.hpp File Reference

The library's version macros. More...

Go to the source code of this file.

Macros

#define ATL_VERSION_MAJOR   0
 The major version.
#define ATL_VERSION_MINOR   0
 The minor version, below 1000.
#define ATL_VERSION_PATCH   0
 The patch version, below 1000.
#define ATL_VERSION_DEV   9000
 The development part: 0 for a release, otherwise unreleased work after ATL_VERSION.
#define ATL_VERSION_ENCODE(major, minor, patch)
 Encodes a release as one integer, major * 1000000 + minor * 1000 + patch.
#define ATL_VERSION   ATL_VERSION_ENCODE(ATL_VERSION_MAJOR, ATL_VERSION_MINOR, ATL_VERSION_PATCH)
 The release this build is, or follows, encoded by ATL_VERSION_ENCODE.
#define ATL_VERSION_STRINGIZE_IMPL(x)
 Stringizes its argument (used by ATL_VERSION_STRING).
#define ATL_VERSION_STRINGIZE(x)
 Stringizes its argument after macro expansion (used by ATL_VERSION_STRING).
#define ATL_VERSION_STRING
 The version as text, such as "0.1.0".

Detailed Description

The library's version macros.

The version is <major>.<minor>.<patch>.<dev>: a dev part other than 0 means unreleased work after that release (0.0.0.9000 is the development version before any release). CMake reads its package version from this header, so the two always agree, and a build without CMake still has the macros.

#include <algotradelib/version>
#if ATL_VERSION >= ATL_VERSION_ENCODE(0, 1, 0)
// something 0.1.0 added
#endif

Definition in file version.hpp.

Macro Definition Documentation

◆ ATL_VERSION

The release this build is, or follows, encoded by ATL_VERSION_ENCODE.

It excludes the development part, so a development checkout compares equal to the release it follows; test ATL_VERSION_DEV to tell them apart.

Definition at line 48 of file version.hpp.

◆ ATL_VERSION_DEV

#define ATL_VERSION_DEV   9000

The development part: 0 for a release, otherwise unreleased work after ATL_VERSION.

Always defined, so #if ATL_VERSION_DEV works under -Wundef.

Definition at line 32 of file version.hpp.

◆ ATL_VERSION_ENCODE

#define ATL_VERSION_ENCODE ( major,
minor,
patch )
Value:
((major) * 1000000 + (minor) * 1000 + (patch))

Encodes a release as one integer, major * 1000000 + minor * 1000 + patch.

Parameters
majorThe major version.
minorThe minor version, below 1000.
patchThe patch version, below 1000.

Definition at line 40 of file version.hpp.

◆ ATL_VERSION_MAJOR

#define ATL_VERSION_MAJOR   0

The major version.

Definition at line 22 of file version.hpp.

◆ ATL_VERSION_MINOR

#define ATL_VERSION_MINOR   0

The minor version, below 1000.

Definition at line 24 of file version.hpp.

◆ ATL_VERSION_PATCH

#define ATL_VERSION_PATCH   0

The patch version, below 1000.

Definition at line 26 of file version.hpp.

◆ ATL_VERSION_STRING

#define ATL_VERSION_STRING
Value:
ATL_VERSION_STRINGIZE(ATL_VERSION_PATCH)
#define ATL_VERSION_MINOR
The minor version, below 1000.
Definition version.hpp:24
#define ATL_VERSION_STRINGIZE(x)
Stringizes its argument after macro expansion (used by ATL_VERSION_STRING).
Definition version.hpp:59
#define ATL_VERSION_PATCH
The patch version, below 1000.
Definition version.hpp:26
#define ATL_VERSION_MAJOR
The major version.
Definition version.hpp:22

The version as text, such as "0.1.0".

Definition at line 68 of file version.hpp.

◆ ATL_VERSION_STRINGIZE

#define ATL_VERSION_STRINGIZE ( x)
Value:
#define ATL_VERSION_STRINGIZE_IMPL(x)
Stringizes its argument (used by ATL_VERSION_STRING).
Definition version.hpp:54

Stringizes its argument after macro expansion (used by ATL_VERSION_STRING).

Parameters
xThe token.

Definition at line 59 of file version.hpp.

◆ ATL_VERSION_STRINGIZE_IMPL

#define ATL_VERSION_STRINGIZE_IMPL ( x)
Value:
#x

Stringizes its argument (used by ATL_VERSION_STRING).

Parameters
xThe token.

Definition at line 54 of file version.hpp.