mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-09-11 21:20:39 +02:00
refactor: Use inline constexpr for string literals in headers
This is needed for the next scripted-diff commit, which would otherwise turn the const from `static const char*` into `inline const char*`.
This commit is contained in:
@@ -25,7 +25,7 @@ class BlockFilter;
|
||||
class CBlockIndex;
|
||||
enum class BlockFilterType : uint8_t;
|
||||
|
||||
static const char* const DEFAULT_BLOCKFILTERINDEX = "0";
|
||||
inline constexpr const char* DEFAULT_BLOCKFILTERINDEX{"0"};
|
||||
|
||||
/** Interval between compact filter checkpoints. See BIP 157. */
|
||||
inline constexpr int CFCHECKPT_INTERVAL = 1000;
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
#ifndef BITCOIN_UNIVALUE_INCLUDE_UNIVALUE_ESCAPES_H
|
||||
#define BITCOIN_UNIVALUE_INCLUDE_UNIVALUE_ESCAPES_H
|
||||
static const char *escapes[256] = {
|
||||
inline constexpr const char* escapes[256]{
|
||||
"\\u0000",
|
||||
"\\u0001",
|
||||
"\\u0002",
|
||||
|
||||
Reference in New Issue
Block a user