Format statements in Fortran modules -
Format statements in Fortran modules -
i have module number of subroutines utilize same set of formats output. right now, have declare formats in every subroutine. there way declare them in module subroutines have access them?
you can store format character @ module level. e.g.
module foo implicit none character(len=20), parameter :: form = "(1x,a)" contains subroutine bar ... write(my_unit, form) "hello, world" end subroutine bar end module foo
module fortran fortran90 fortran95 formats
Comments
Post a Comment