aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2016-05-27 16:02:27 +0100
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2016-08-28 21:27:38 +0100
commit0ff830542688959280b0513437fb45b21baf91d8 (patch)
tree013db784eccd475d5d6124cda80667578f0d18cb /src
parentAdded note on generating H2 (diff)
downloadmonero-0ff830542688959280b0513437fb45b21baf91d8.tar.xz
serialization: declare do_serialize specializations before use
This lets my gcc picks those instead of the generic template where appropriate (and then fail since std::vector<something> does not have a serialize method.
Diffstat (limited to 'src')
-rw-r--r--src/ringct/rctTypes.h2
-rw-r--r--src/serialization/vector.h5
2 files changed, 6 insertions, 1 deletions
diff --git a/src/ringct/rctTypes.h b/src/ringct/rctTypes.h
index 1b3cb8219..b56a330b1 100644
--- a/src/ringct/rctTypes.h
+++ b/src/ringct/rctTypes.h
@@ -173,7 +173,7 @@ namespace rct {
//H2 contains 2^i H in each index, i.e. H, 2H, 4H, 8H, ...
//This is used for the range proofG
- //You can regenerate this by running python2 Test.py HPow2 in the MiniNero repo
+ //You can regenerate this by running python2 Test.py HPow2 in the MiniNero repo
static const key64 H2 = {{0x8b, 0x65, 0x59, 0x70, 0x15, 0x37, 0x99, 0xaf, 0x2a, 0xea, 0xdc, 0x9f, 0xf1, 0xad, 0xd0, 0xea, 0x6c, 0x72, 0x51, 0xd5, 0x41, 0x54, 0xcf, 0xa9, 0x2c, 0x17, 0x3a, 0x0d, 0xd3, 0x9c, 0x1f, 0x94},
{0x8f, 0xaa, 0x44, 0x8a, 0xe4, 0xb3, 0xe2, 0xbb, 0x3d, 0x4d, 0x13, 0x09, 0x09, 0xf5, 0x5f, 0xcd, 0x79, 0x71, 0x1c, 0x1c, 0x83, 0xcd, 0xbc, 0xca, 0xdd, 0x42, 0xcb, 0xe1, 0x51, 0x5e, 0x87, 0x12},
{0x12, 0xa7, 0xd6, 0x2c, 0x77, 0x91, 0x65, 0x4a, 0x57, 0xf3, 0xe6, 0x76, 0x94, 0xed, 0x50, 0xb4, 0x9a, 0x7d, 0x9e, 0x3f, 0xc1, 0xe4, 0xc7, 0xa0, 0xbd, 0xe2, 0x9d, 0x18, 0x7e, 0x9c, 0xc7, 0x1d},
diff --git a/src/serialization/vector.h b/src/serialization/vector.h
index a2a69f841..7f2bc78ba 100644
--- a/src/serialization/vector.h
+++ b/src/serialization/vector.h
@@ -32,6 +32,11 @@
#include "serialization.h"
+template <template <bool> class Archive, class T>
+bool do_serialize(Archive<false> &ar, std::vector<T> &v);
+template <template <bool> class Archive, class T>
+bool do_serialize(Archive<true> &ar, std::vector<T> &v);
+
namespace serialization
{
namespace detail