diff options
Diffstat (limited to 'include/util')
| -rw-r--r-- | include/util/types.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/include/util/types.h b/include/util/types.h index bac0246..cf61412 100644 --- a/include/util/types.h +++ b/include/util/types.h @@ -73,10 +73,16 @@ const ShardID INVALID_SHID = {-1, -1}; typedef ssize_t level_index; -typedef struct { - level_index source; +typedef struct ReconstructionTask { + std::vector<level_index> sources; level_index target; size_t reccnt; + + void add_source(level_index source, size_t cnt) { + sources.push_back(source); + reccnt += cnt; + } + } ReconstructionTask; class ReconstructionVector { @@ -91,7 +97,7 @@ public: } void add_reconstruction(level_index source, level_index target, size_t reccnt) { - m_tasks.push_back({source, target, reccnt}); + m_tasks.push_back({{source}, target, reccnt}); total_reccnt += reccnt; } |