Skip to content

Commit

Permalink
Declared intents for arguments in MOM_checksums
Browse files Browse the repository at this point in the history
  Added intent declarations for the arguments to several functions in
MOM_checksums.  All answers are bitwise identical.
  • Loading branch information
Hallberg-NOAA committed May 3, 2018
1 parent 6f7f67b commit 688aaef
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions src/framework/MOM_checksums.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1155,14 +1155,14 @@ end subroutine chksum_u_3d
!---chksum_general interface routines
!> Return the bitcount of an arbitrarily sized 3d array
integer function chksum_general_3d( array, scale_factor, istart, iend, jstart, jend, kstart, kend ) result(subchk)
real, dimension(:,:,:) :: array !< Array to be checksummed
real, optional :: scale_factor !< Factor to scale array by before checksum
integer, optional :: istart !< Starting index in the i-direction
integer, optional :: iend !< Ending index in the i-direction
integer, optional :: jstart !< Starting index in the j-direction
integer, optional :: jend !< Ending index in the j-direction
integer, optional :: kstart !< Starting index in the k-direction
integer, optional :: kend !< Ending index in the k-direction
real, dimension(:,:,:), intent(in) :: array !< Array to be checksummed
real, optional, intent(in) :: scale_factor !< Factor to scale array by before checksum
integer, optional, intent(in) :: istart !< Starting index in the i-direction
integer, optional, intent(in) :: iend !< Ending index in the i-direction
integer, optional, intent(in) :: jstart !< Starting index in the j-direction
integer, optional, intent(in) :: jend !< Ending index in the j-direction
integer, optional, intent(in) :: kstart !< Starting index in the k-direction
integer, optional, intent(in) :: kend !< Ending index in the k-direction
integer :: i, j, k, bc, is, ie, js, je, ks, ke
real :: scale

Expand Down Expand Up @@ -1192,11 +1192,11 @@ end function chksum_general_3d
!> Return the bitcount of an arbitrarily sized 2d array by promotion to a 3d array
integer function chksum_general_2d( array_2d, scale_factor, istart, iend, jstart, jend )
real, dimension(:,:) :: array_2d !< Array to be checksummed
real, optional :: scale_factor !< Factor to scale array by before checksum
integer, optional :: istart !< Starting index in the i-direction
integer, optional :: iend !< Ending index in the i-direction
integer, optional :: jstart !< Starting index in the j-direction
integer, optional :: jend !< Ending index in the j-direction
real, optional, intent(in) :: scale_factor !< Factor to scale array by before checksum
integer, optional, intent(in) :: istart !< Starting index in the i-direction
integer, optional, intent(in) :: iend !< Ending index in the i-direction
integer, optional, intent(in) :: jstart !< Starting index in the j-direction
integer, optional, intent(in) :: jend !< Ending index in the j-direction
integer :: is, ie, js, je
real, dimension(:,:,:), allocatable :: array_3d !< Promotion from 2d to 3d array

Expand Down Expand Up @@ -1512,8 +1512,8 @@ end function is_NaN_0d
!> This function returns .true. if any element of x is a NaN, and .false. otherwise.
function is_NaN_1d(x, skip_mpp)
real, dimension(:), intent(in) :: x !< The array to be checked for NaNs.
logical, optional, intent(in) :: skip_mpp !< If true, only check this array only on the local PE (default false).
logical :: is_NaN_1d
logical, optional :: skip_mpp !< If true, only check this array only on the local PE (default false).

integer :: i, n
logical :: call_mpp
Expand Down

0 comments on commit 688aaef

Please sign in to comment.