mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-09-07 15:01:17 +02:00
refactor: Move STRINGIZE macro to macros.h
This is a move-only change.
This commit is contained in:
@@ -5,6 +5,8 @@
|
|||||||
#ifndef BITCOIN_CLIENTVERSION_H
|
#ifndef BITCOIN_CLIENTVERSION_H
|
||||||
#define BITCOIN_CLIENTVERSION_H
|
#define BITCOIN_CLIENTVERSION_H
|
||||||
|
|
||||||
|
#include <util/macros.h>
|
||||||
|
|
||||||
#if defined(HAVE_CONFIG_H)
|
#if defined(HAVE_CONFIG_H)
|
||||||
#include <config/bitcoin-config.h>
|
#include <config/bitcoin-config.h>
|
||||||
#endif //HAVE_CONFIG_H
|
#endif //HAVE_CONFIG_H
|
||||||
@@ -14,13 +16,6 @@
|
|||||||
#error Client version information missing: version is not defined by bitcoin-config.h or in any other way
|
#error Client version information missing: version is not defined by bitcoin-config.h or in any other way
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/**
|
|
||||||
* Converts the parameter X to a string after macro replacement on X has been performed.
|
|
||||||
* Don't merge these into one macro!
|
|
||||||
*/
|
|
||||||
#define STRINGIZE(X) DO_STRINGIZE(X)
|
|
||||||
#define DO_STRINGIZE(X) #X
|
|
||||||
|
|
||||||
//! Copyright string used in Windows .rc files
|
//! Copyright string used in Windows .rc files
|
||||||
#define COPYRIGHT_STR "2009-" STRINGIZE(COPYRIGHT_YEAR) " " COPYRIGHT_HOLDERS_FINAL
|
#define COPYRIGHT_STR "2009-" STRINGIZE(COPYRIGHT_YEAR) " " COPYRIGHT_HOLDERS_FINAL
|
||||||
|
|
||||||
|
@@ -8,4 +8,11 @@
|
|||||||
#define PASTE(x, y) x ## y
|
#define PASTE(x, y) x ## y
|
||||||
#define PASTE2(x, y) PASTE(x, y)
|
#define PASTE2(x, y) PASTE(x, y)
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Converts the parameter X to a string after macro replacement on X has been performed.
|
||||||
|
* Don't merge these into one macro!
|
||||||
|
*/
|
||||||
|
#define STRINGIZE(X) DO_STRINGIZE(X)
|
||||||
|
#define DO_STRINGIZE(X) #X
|
||||||
|
|
||||||
#endif // BITCOIN_UTIL_MACROS_H
|
#endif // BITCOIN_UTIL_MACROS_H
|
||||||
|
Reference in New Issue
Block a user