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
subroutine datestr_to_date(date_str,format_str,date_array)!! Converts date string to a date array based on the format string!! !! Example:!! call datestr_to_date("20190429123005", "yyyymmdd", date_array_out)!! Returns:!! date_arrat_out = [2019, 4, 29, 0, 0, 0]character(*),intent(in)::date_str!! Date string [yyyymmddHHMMSS]character(*),intent(in)::format_str!! Format stringinteger,intent(out)::date_array(6)!! Datetime [y,m,d,h,m,s]! Local variablesinteger::pos! Extract elements of the date stringpos=index(format_str,'yyyy')if(pos.gt.0)then read(date_str(pos:pos+3),*)date_array(1)elsedate_array(1)=0end ifpos=index(format_str,'mm')if(pos.gt.0)then read(date_str(pos:pos+1),*)date_array(2)elsedate_array(2)=0end ifpos=index(format_str,'dd')if(pos.gt.0)then read(date_str(pos:pos+1),*)date_array(3)elsedate_array(3)=0end ifpos=index(format_str,'HH')if(pos.gt.0)then read(date_str(pos:pos+1),*)date_array(4)elsedate_array(4)=0end ifpos=index(format_str,'MM')if(pos.gt.0)then read(date_str(pos:pos+1),*)date_array(5)elsedate_array(5)=0end ifpos=index(format_str,'SS')if(pos.gt.0)then read(date_str(pos:pos+1),*)date_array(6)elsedate_array(6)=0end if end subroutine datestr_to_date