Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 0 additions & 29 deletions src/framework/MOM_string_functions.F90
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ module MOM_string_functions
public extract_real
public remove_spaces
public slasher
public append_substring

contains

Expand Down Expand Up @@ -419,34 +418,6 @@ function slasher(dir)
endif
end function slasher

!> append a string (substring) to another string (string_in) and return the
!! concatenated string (string_out)
function append_substring(string_in, substring) result(string_out)
character(len=*), intent(in) :: string_in !< input string
character(len=*), intent(in) :: substring !< string to append string_in
! local
character(len=1024) :: string_out
character(len=1024) :: string_joined
integer :: string_in_length
integer :: substring_length

string_out = ''
string_joined = ''
string_in_length = 0
substring_length = 0

string_in_length = len_trim(string_in)
substring_length = len_trim(substring)

if (string_in_length > 0) then
if (substring_length > 0) then
string_joined = trim(string_in)//trim(substring)
string_out(1:len_trim(string_joined)) = trim(string_joined)
endif
endif

end function append_substring

!> \namespace mom_string_functions
!!
!! By Alistair Adcroft and Robert Hallberg, last updated Sept. 2013.
Expand Down