Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.
Source Code
function file_length(file)result(lines)integer::linescharacter(len=*)::fileinteger::ifile,ierr,poslogical::IOfile,bool,bool1,bool2character(len=256)::bufferinquire(file=reg(file),exist=IOfile)if(.not.IOfile)then inquire(file=reg(file)//".gz",exist=IOfile)if(IOfile)call file_gunzip(reg(file))endiflines=0if(.not.IOfile)then write(*,*)'Cannot read +'//reg(file)//'. Skip file_size'return endif open(99,file=reg(file))ierr=0do while(ierr==0)lines=lines+1read(99,*,iostat=ierr)bufferbool1=scan(buffer,"#").ne.0bool2=len_trim(buffer).eq.0if(bool1.OR.bool2)lines=lines-1enddolines=lines-1write(*,'(A,I9,A)')'there are',lines,' lines in +'//reg(file)rewind(99)close(99)end function file_length