diff options
author | 2019-10-01 20:21:34 -0700 | |
---|---|---|
committer | 2019-10-01 20:21:34 -0700 | |
commit | 0f32e809c513ea122361e018a04374a599f1e571 (patch) | |
tree | 8ab84dd8d78178c0ed658f95a0d977b939ef3458 /Source/Particles/Sorting/Partition.cpp | |
parent | 328d71b768c8ab79136eef3b6b46b72f39910c08 (diff) | |
download | WarpX-0f32e809c513ea122361e018a04374a599f1e571.tar.gz WarpX-0f32e809c513ea122361e018a04374a599f1e571.tar.zst WarpX-0f32e809c513ea122361e018a04374a599f1e571.zip |
Edit const correctness
Diffstat (limited to 'Source/Particles/Sorting/Partition.cpp')
-rw-r--r-- | Source/Particles/Sorting/Partition.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/Particles/Sorting/Partition.cpp b/Source/Particles/Sorting/Partition.cpp index badd35f02..d1455249a 100644 --- a/Source/Particles/Sorting/Partition.cpp +++ b/Source/Particles/Sorting/Partition.cpp @@ -60,12 +60,12 @@ PhysicalParticleContainer::PartitionParticlesInBuffers( // - Find the indices that reorder particles so that the last particles // are in the larger buffer fillWithConsecutiveIntegers( pid ); - auto sep = stablePartition( pid.begin(), pid.end(), inexflag ); + auto const sep = stablePartition( pid.begin(), pid.end(), inexflag ); // At the end of this step, `pid` contains the indices that should be used to // reorder the particles, and `sep` is the position in the array that // separates the particles that deposit/gather on the fine patch (first part) // and the particles that deposit/gather in the buffers (last part) - long n_fine = iteratorDistance(pid.begin(), sep); + long const n_fine = iteratorDistance(pid.begin(), sep); // Number of particles on fine patch, i.e. outside of the larger buffer // Second, among particles that are in the larger buffer, partition @@ -94,7 +94,7 @@ PhysicalParticleContainer::PartitionParticlesInBuffers( // the smaller buffer, by looking up the mask. Store the answer in `inexflag`. amrex::ParallelFor( np - n_fine, fillBufferFlag(pti, bmasks, inexflag, Geom(lev), n_fine) ); - auto sep2 = stablePartition( sep, pid.end(), inexflag ); + auto const sep2 = stablePartition( sep, pid.end(), inexflag ); if (bmasks == gather_masks) { nfine_gather = iteratorDistance(pid.begin(), sep2); |