str_split Subroutine

public subroutine str_split(str, delimiter, before)

Routine finds the first instance of a character from delims in the the string str. The characters before the found delimiter are output in before. The characters after the found delimiter are output in str. Repeated applications of this routine can be used to parse a string into its component parts. Multiple whitespaces of str are compacted into a single whitespace before splitting begins. If either str or delimiter is empty, an empty string is retured in before and str remains unchanged.

Arguments

Type IntentOptional AttributesName
character(len=*), intent(inout) :: str
character(len=*), intent(in) :: delimiter
character(len=:), intent(out), allocatable:: before

Calls

proc~~str_split~~CallsGraph proc~str_split str_split proc~str_compact str_compact proc~str_split->proc~str_compact

Called by

proc~~str_split~~CalledByGraph proc~str_split str_split proc~read_config read_config proc~read_config->proc~str_split proc~run run proc~run->proc~read_config program~main main program~main->proc~run

Contents

None