Use reference when accessing Schedule actions
This commit is contained in:
@@ -637,7 +637,7 @@ captureDeclaredActionxData( const Opm::Schedule& sched,
|
||||
const std::vector<int>& actDims,
|
||||
const std::size_t simStep)
|
||||
{
|
||||
const auto acts = sched.actions(simStep);
|
||||
const auto& acts = sched.actions(simStep);
|
||||
std::size_t act_ind = 0;
|
||||
for (auto actx_it = acts.begin(); actx_it < acts.end(); actx_it++) {
|
||||
{
|
||||
|
||||
@@ -722,7 +722,7 @@ namespace {
|
||||
act_res_stat(const Opm::Schedule& sched, const Opm::SummaryState& smry, const std::size_t sim_step) {
|
||||
std::vector<Opm::Action::Result> act_res;
|
||||
std::vector<std::string> act_name;
|
||||
const auto acts = sched.actions(sim_step);
|
||||
const auto& acts = sched.actions(sim_step);
|
||||
Opm::Action::Context context(smry);
|
||||
auto sim_time = sched.simTime(sim_step);
|
||||
for (const auto& action : acts.pending(sim_time)) {
|
||||
|
||||
Reference in New Issue
Block a user