Skip to content

Commit

Permalink
correcting solver builder constructor (#616)
Browse files Browse the repository at this point in the history
* correcting solver builder constructor

* fix a bug

---------

Co-authored-by: Jiwon Gim <[email protected]>
  • Loading branch information
K20shores and boulderdaze authored Aug 7, 2024
1 parent 68cd3e2 commit 6b1c58a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions include/micm/solver/solver.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,13 @@ namespace micm
Solver& operator=(const Solver&) = delete;

Solver(Solver&& other)
: number_of_grid_cells_(other.number_of_grid_cells_),
: solver_(std::move(other.solver_)),
processes_(std::move(other.processes_)),
number_of_grid_cells_(other.number_of_grid_cells_),
number_of_species_(other.number_of_species_),
number_of_reactions_(other.number_of_reactions_),
state_parameters_(other.state_parameters_)
{
std::swap(this->solver_, other.solver_);
std::swap(this->processes_, other.processes_);
}
Solver& operator=(Solver&& other)
{
Expand All @@ -55,7 +55,7 @@ namespace micm
number_of_species_ = other.number_of_species_;
number_of_reactions_ = other.number_of_reactions_;
state_parameters_ = other.state_parameters_;
std::swap(this->solver_, other.processes_);
std::swap(this->processes_, other.processes_);
return *this;
}

Expand Down

0 comments on commit 6b1c58a

Please sign in to comment.