diff options
| author | Evan Klitzke <[email protected]> | 2018-02-26 18:45:57 -0800 |
|---|---|---|
| committer | Evan Klitzke <[email protected]> | 2018-02-27 11:42:06 -0800 |
| commit | f0e7aa702095b22ba57a763c5c093e15d41586d1 (patch) | |
| tree | e9acd6a0af2ab274264d5b2191984a9992c5b712 /src/compat.h | |
| parent | Merge #12083: Improve getchaintxstats test coverage (diff) | |
| download | discoin-f0e7aa702095b22ba57a763c5c093e15d41586d1.tar.xz discoin-f0e7aa702095b22ba57a763c5c093e15d41586d1.zip | |
Add new prevector benchmarks.
This prepares for a series of two additional commits which optimize
prevector performance.
Diffstat (limited to 'src/compat.h')
| -rw-r--r-- | src/compat.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/compat.h b/src/compat.h index aae84b118..8a0f90130 100644 --- a/src/compat.h +++ b/src/compat.h @@ -10,6 +10,16 @@ #include <config/bitcoin-config.h> #endif +#include <type_traits> + +// GCC 4.8 is missing some C++11 type_traits, +// https://www.gnu.org/software/gcc/gcc-5/changes.html +#if defined(__GNUC__) && __GNUC__ < 5 +#define IS_TRIVIALLY_CONSTRUCTIBLE std::is_trivial +#else +#define IS_TRIVIALLY_CONSTRUCTIBLE std::is_trivially_constructible +#endif + #ifdef WIN32 #ifdef _WIN32_WINNT #undef _WIN32_WINNT |