Skip to content

Commit

Permalink
make old compilers more happy
Browse files Browse the repository at this point in the history
  • Loading branch information
boeschf committed Oct 16, 2024
1 parent 34f27df commit 83c4846
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/unit/test_event_stream.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ result<Stream> multi_step() {
for (std::size_t cell=0; cell<num_cells; ++cell) {
for (std::size_t mech_id=0; mech_id<num_mechanisms; ++mech_id) {
for (std::size_t mech_index=0; mech_index<num_targets_per_mechanism_and_cell; ++mech_index) {
handles.emplace_back(mech_id, mech_index);
handles.emplace_back(static_cast<cell_local_size_type>(mech_id), static_cast<cell_local_size_type>(mech_index));
}
}
divs[cell+1] = divs[cell] + num_mechanisms*num_targets_per_mechanism_and_cell;
Expand All @@ -139,7 +139,7 @@ result<Stream> multi_step() {
auto target = mech_id*num_targets_per_mechanism_and_cell + mech_index;
auto time = time_dist(gen);
auto weight = 0.0f;
events[cell].emplace_back(target, time, weight);
events[cell].emplace_back(static_cast<cell_lid_type>(target), time, weight);
}

// sort events by time
Expand Down Expand Up @@ -199,7 +199,7 @@ result<Stream> multi_step() {
auto mech_id = handle.mech_id;
auto mech_index = handle.mech_index;
event.weight = cc++;
res.expected[mech_id][step].emplace_back(mech_index, event.weight);
res.expected[mech_id][step].push_back(arb_deliverable_event_data{mech_index, event.weight});
}

// initialize event streams
Expand Down

0 comments on commit 83c4846

Please sign in to comment.