From ddf7f6100a6380eb2cb8af8932c9c101e394fe5f Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Sun, 21 Apr 2019 01:01:02 +0200 Subject: [PATCH] fixed reading/writing hyperpoints to use the actual number of dimensions --- hyper.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hyper.h b/hyper.h index 9e18e97b..82974db6 100644 --- a/hyper.h +++ b/hyper.h @@ -4546,6 +4546,9 @@ inline void hread(hstream& hs, ld& h) { double d; hs.read_chars((char*) &d, size template void hwrite(hstream& hs, const array& a) { for(auto &ae: a) hwrite(hs, ae); } template void hread(hstream& hs, array& a) { for(auto &ae: a) hread(hs, ae); } +inline void hread(hstream& hs, hyperpoint& h) { for(int i=0; i void hwrite(hstream& hs, const vector& a) { hwrite(hs, isize(a)); for(auto &ae: a) hwrite(hs, ae); } template void hread(hstream& hs, vector& a) { a.resize(hs.get()); for(auto &ae: a) hread(hs, ae); }