Skip to content

Commit

Permalink
update to Fortran 2018 standard
Browse files Browse the repository at this point in the history
  • Loading branch information
mjreno committed Jul 15, 2024
1 parent 3598862 commit 1e84fb7
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 11 deletions.
2 changes: 1 addition & 1 deletion meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ project(
'b_vscrt=static_from_buildtype', # Link runtime libraries statically on Windows
'optimization=2',
'debug=false',
'fortran_std=f2008',
'fortran_std=f2018',
])

if get_option('optimization') == '3'
Expand Down
29 changes: 19 additions & 10 deletions src/Solution/LinearMethods/ImsReordering.f90
Original file line number Diff line number Diff line change
Expand Up @@ -300,12 +300,13 @@ subroutine ims_md(n, nja, ia, ja, mmax, v, l, head, last, next, &
! -- local
integer(I4B) :: tag
integer(I4B) :: dmin
integer(I4B) :: vk
integer(I4B) :: ek
integer(I4B), pointer :: vk
integer(I4B), pointer :: ek
integer(I4B) :: tail
integer(I4B) :: k

equivalence(vk, ek)
allocate (vk)
ek => vk
!
! initialization
tag = 0
Expand Down Expand Up @@ -353,6 +354,8 @@ subroutine ims_md(n, nja, ia, ja, mmax, v, l, head, last, next, &
last(next(k)) = k
end do
!
deallocate (vk)
!
return
end subroutine ims_md

Expand Down Expand Up @@ -482,15 +485,16 @@ subroutine ims_mdm(n, mmax, vk, tail, v, l, last, next, mark)
integer(I4B) :: tag
integer(I4B) :: s
integer(I4B) :: ls
integer(I4B) :: vs
integer(I4B) :: es
integer(I4B), pointer :: vs
integer(I4B), pointer :: es
integer(I4B) :: b
integer(I4B) :: lb
integer(I4B) :: vb
integer(I4B) :: blp
integer(I4B) :: blpmax

equivalence(vs, es)
allocate (vs)
es => vs
!
! initialize tag and list of uneliminated neighbors
tag = mark(vk)
Expand Down Expand Up @@ -535,6 +539,8 @@ subroutine ims_mdm(n, mmax, vk, tail, v, l, last, next, mark)
!
! terminate list of uneliminated neighbors
5 l(tail) = 0
!
deallocate (vs)
!
return
end subroutine ims_mdm
Expand Down Expand Up @@ -681,8 +687,8 @@ subroutine ims_mdu(n, mmax, ek, dmin, v, l, head, last, next, mark)
integer(I4B) :: evi
integer(I4B) :: dvi
integer(I4B) :: s
integer(I4B) :: vs
integer(I4B) :: es
integer(I4B), pointer :: vs
integer(I4B), pointer :: es
integer(I4B) :: b
integer(I4B) :: vb
integer(I4B) :: ilp
Expand All @@ -691,7 +697,8 @@ subroutine ims_mdu(n, mmax, ek, dmin, v, l, head, last, next, mark)
integer(I4B) :: blpmax
integer(I4B) :: i

equivalence(vs, es)
allocate (vs)
es => vs
!
! initialize tag
tag = mark(ek) - last(ek)
Expand Down Expand Up @@ -768,7 +775,9 @@ subroutine ims_mdu(n, mmax, ek, dmin, v, l, head, last, next, mark)
!
end do louter !10
!
11 return
11 deallocate (vs)
!
return
end subroutine ims_mdu

end module IMSReorderingModule

0 comments on commit 1e84fb7

Please sign in to comment.