Skip to content

Commit 301b9a2

Browse files
committed
Fix copy and assignment operators.
1 parent 9f0ed4e commit 301b9a2

1 file changed

Lines changed: 13 additions & 2 deletions

File tree

wrapper/Convert/SireOpenMM/openmmmolecule.cpp

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2505,7 +2505,11 @@ PerturbableOpenMMMolecule::PerturbableOpenMMMolecule(const PerturbableOpenMMMole
25052505
constraint_idxs(other.constraint_idxs),
25062506
start_atom_idx(other.start_atom_idx),
25072507
is_improper(other.is_improper),
2508-
is_rest2(other.is_rest2)
2508+
is_rest2(other.is_rest2),
2509+
cmap_grid0(other.cmap_grid0),
2510+
cmap_grid1(other.cmap_grid1),
2511+
cmap_grid_sizes(other.cmap_grid_sizes),
2512+
cmap_atoms(other.cmap_atoms)
25092513
{
25102514
}
25112515

@@ -2533,7 +2537,9 @@ bool PerturbableOpenMMMolecule::operator==(const PerturbableOpenMMMolecule &othe
25332537
lj_scl0 == other.lj_scl0 and lj_scl1 == other.lj_scl1 and
25342538
to_ghost_idxs == other.to_ghost_idxs and from_ghost_idxs == other.from_ghost_idxs and
25352539
exception_atoms == other.exception_atoms and exception_idxs == other.exception_idxs and
2536-
perturbable_constraints == other.perturbable_constraints and constraint_idxs == other.constraint_idxs;
2540+
perturbable_constraints == other.perturbable_constraints and constraint_idxs == other.constraint_idxs and
2541+
cmap_grid0 == other.cmap_grid0 and cmap_grid1 == other.cmap_grid1 and
2542+
cmap_grid_sizes == other.cmap_grid_sizes and cmap_atoms == other.cmap_atoms;
25372543
}
25382544

25392545
/** Comparison operator */
@@ -2602,6 +2608,11 @@ PerturbableOpenMMMolecule &PerturbableOpenMMMolecule::operator=(const Perturbabl
26022608
perturbable_constraints = other.perturbable_constraints;
26032609
constraint_idxs = other.constraint_idxs;
26042610

2611+
cmap_grid0 = other.cmap_grid0;
2612+
cmap_grid1 = other.cmap_grid1;
2613+
cmap_grid_sizes = other.cmap_grid_sizes;
2614+
cmap_atoms = other.cmap_atoms;
2615+
26052616
Property::operator=(other);
26062617
}
26072618

0 commit comments

Comments
 (0)