module m_name_of_module !----------------------------------------------------------------------- ! This file is part of ESTEL-3D ! Copyright (c) EDF 2007 !----------------------------------------------------------------------- ! Function : Blah blah ! ! List of PUBLIC Subroutines : ! ---------------------------- ! sub1 : does stuff ! sub2 : does some other stuff ! ! Any other general comments here !----------------------------------------------------------------------- use m_thing ! Note that declarations are private, by default. ! This avoids interference with similar variables declared by other ! modules. private ! PUBLIC Subroutines !------------------- public :: sub1 public :: sub2 ! PUBLIC Variables !------------------ integer, public :: foo !PRIVATE Variables !------------------ integer :: bar !----------------------------------------------------------------------- contains subroutine sub1( arg1, & arg2, & longarg3 ) !----------------------------------------------------------------------- ! Function: Does stuff !----------------------------------------------------------------------- implicit none !----------------------------------------------------------------------- ! Arguments double precision, intent(in) :: arg1 ! I am argument #1 integer , intent(in) :: arg2 ! I am argument #2 character :: longarg3 ! I am argument #3 !----------------------------------------------------------------------- ! Local declarations integer :: i, j !----------------------------------------------------------------------- if (debug) call proc_begin('sub1') !----------------------------------------------------------------------- ! ACTUAL CODE HERE !----------------------------------------------------------------------- if (debug) call proc_end('sub1') !----------------------------------------------------------------------- return end subroutine sub1 subroutine sub2( arg1, & arg2, & longarg3 ) !----------------------------------------------------------------------- ! Function: Does some other stuff !----------------------------------------------------------------------- implicit none !----------------------------------------------------------------------- ! Arguments double precision, intent(in) :: arg1 ! I am argument #1 integer , intent(in) :: arg2 ! I am argument #2 character :: longarg3 ! I am argument #3 !----------------------------------------------------------------------- ! Local declarations integer :: i, j !----------------------------------------------------------------------- if (debug) call proc_begin('sub2') !----------------------------------------------------------------------- ! ACTUAL CODE HERE !----------------------------------------------------------------------- if (debug) call proc_end('sub2') !----------------------------------------------------------------------- return end subroutine sub2 !----------------------------------------------------------------------- end module m_modulename