diff options
Diffstat (limited to 'Source/Laser/LaserParticleContainer.cpp')
-rw-r--r-- | Source/Laser/LaserParticleContainer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Laser/LaserParticleContainer.cpp b/Source/Laser/LaserParticleContainer.cpp index a330200cc..1d9689979 100644 --- a/Source/Laser/LaserParticleContainer.cpp +++ b/Source/Laser/LaserParticleContainer.cpp @@ -249,8 +249,8 @@ LaserParticleContainer::InitData (int lev) { auto compute_min_max = [&](Real x, Real y, Real z){ const Vector<Real>& pos_plane = InverseTransform({x, y, z}); - int i = pos_plane[0]/S_X; - int j = pos_plane[1]/S_Y; + auto i = static_cast<int>(pos_plane[0]/S_X); + auto j = static_cast<int>(pos_plane[1]/S_Y); plane_lo[0] = std::min(plane_lo[0], i); plane_lo[1] = std::min(plane_lo[1], j); plane_hi[0] = std::max(plane_hi[0], i); |