From 8ba4272f6c5e4b0aa5f710ee20065da2508cf264 Mon Sep 17 00:00:00 2001 From: David Minton Date: Thu, 19 Aug 2021 00:06:25 -0400 Subject: [PATCH] Added explicit ranges to whole array operations --- src/symba/symba_util.f90 | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/symba/symba_util.f90 b/src/symba/symba_util.f90 index a80c8e646..08b5728e8 100644 --- a/src/symba/symba_util.f90 +++ b/src/symba/symba_util.f90 @@ -455,15 +455,15 @@ module subroutine symba_util_rearray_pl(self, system, param) end if ! Reset all of the status flags for this body - where(pl%status(:) /= INACTIVE) - pl%status(:) = ACTIVE - pl%ldiscard(:) = .false. - pl%lcollision(:) = .false. - pl%lmtiny(:) = pl%Gmass(:) > param%GMTINY - pl%lmask(:) = .true. + where(pl%status(1:pl%nbody) /= INACTIVE) + pl%status(1:pl%nbody) = ACTIVE + pl%ldiscard(1:pl%nbody) = .false. + pl%lcollision(1:pl%nbody) = .false. + pl%lmtiny(1:pl%nbody) = pl%Gmass(1:pl%nbody) > param%GMTINY + pl%lmask(1:pl%nbody) = .true. elsewhere - pl%ldiscard(:) = .true. - pl%lmask(:) = .false. + pl%ldiscard(1:pl%nbody) = .true. + pl%lmask(1:pl%nbody) = .false. end where pl%nplm = count(pl%lmtiny(1:pl%nbody) .and. pl%lmask(1:pl%nbody))