From 68281f4dc0364abfe6e4a4c30844391b6f1f5d43 Mon Sep 17 00:00:00 2001 From: dnotestein Date: Tue, 11 Feb 2014 23:10:24 -0500 Subject: [PATCH 1/2] Added get_typename function needed by new leveldb database upgrading code (uint160 is stored in blockchain database). --- include/fc/crypto/ripemd160.hpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/fc/crypto/ripemd160.hpp b/include/fc/crypto/ripemd160.hpp index 5cf404d..e2d13a9 100644 --- a/include/fc/crypto/ripemd160.hpp +++ b/include/fc/crypto/ripemd160.hpp @@ -1,6 +1,8 @@ #pragma once #include #include +#include + namespace fc{ class sha512; @@ -75,6 +77,8 @@ class ripemd160 typedef ripemd160 uint160_t; typedef ripemd160 uint160; + template<> struct get_typename { static const char* name() { return "uint160"; } }; + } // namespace fc namespace std From 5b103e5754654fa1c06cb916102ba657a87615ed Mon Sep 17 00:00:00 2001 From: dnotestein Date: Sat, 15 Feb 2014 22:48:09 -0500 Subject: [PATCH 2/2] Add get_typename for std::vector --- include/fc/reflect/typename.hpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/fc/reflect/typename.hpp b/include/fc/reflect/typename.hpp index 0fbb1dd..20cd1f6 100644 --- a/include/fc/reflect/typename.hpp +++ b/include/fc/reflect/typename.hpp @@ -1,5 +1,6 @@ #pragma once #include +#include namespace fc { class value; template class get_typename{}; @@ -18,4 +19,6 @@ namespace fc { template<> struct get_typename { static const char* name() { return "char"; } }; template<> struct get_typename { static const char* name() { return "string"; } }; template<> struct get_typename { static const char* name() { return "value"; } }; + template<> struct get_typename> { static const char* name() { return "std::vector"; } }; + }