Skip to content

Commit

Permalink
Name the types
Browse files Browse the repository at this point in the history
  • Loading branch information
thorstenhater committed Jan 7, 2025
1 parent 78d8cc3 commit d200826
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions arbor/backends/event_stream_base.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
#include "backends/event_stream_state.hpp"
#include "event_lane.hpp"
#include "timestep_range.hpp"
#include "util/partition.hpp"

ARB_SERDES_ENABLE_EXT(arb_deliverable_event_data, mech_index, weight);

Expand Down Expand Up @@ -119,7 +118,7 @@ struct spike_event_stream_base: event_stream_base<deliverable_event> {
arb_assert(div + evt.target < handles.size());
const auto& handle = handles[div + evt.target];
auto& stream = streams[handle.mech_id];
stream.spikes_.emplace_back({step, handle.mech_index, evt.time, evt.weight});
stream.spikes_.emplace_back(spike_data{step, handle.mech_index, evt.time, evt.weight});
stream.ev_spans_[step + 1]++;
}
++cell;
Expand All @@ -139,7 +138,7 @@ struct spike_event_stream_base: event_stream_base<deliverable_event> {
std::sort(stream.spikes_.begin(), stream.spikes_.end());
// copy temporary deliverable_events into stream's ev_data_
stream.ev_data_.reserve(stream.spikes_.size());
for (const auto& spike: stream.spikes_) stream.ev_data_.emplace_back({spike.mech_index, spike.weight});
for (const auto& spike: stream.spikes_) stream.ev_data_.emplace_back(event_data_type{spike.mech_index, spike.weight});
// delegate to derived class init: static cast necessary to access protected init()
static_cast<spike_event_stream_base&>(stream).init();
// });
Expand Down

0 comments on commit d200826

Please sign in to comment.