integer_to_string Subroutine

private subroutine integer_to_string(i, s)

Integer to string conversion.

Arguments

Type IntentOptional Attributes Name
integer, intent(in), optional :: i

integer value

character(len=*), intent(out) :: s

integer value stringified


Called by

proc~~integer_to_string~~CalledByGraph proc~integer_to_string integer_to_string proc~initialize pyplot%initialize proc~initialize->proc~integer_to_string proc~optional_int_to_string optional_int_to_string proc~initialize->proc~optional_int_to_string proc~optional_int_to_string->proc~integer_to_string proc~add_3d_plot pyplot%add_3d_plot proc~add_3d_plot->proc~optional_int_to_string proc~add_contour pyplot%add_contour proc~add_contour->proc~optional_int_to_string proc~add_errorbar pyplot%add_errorbar proc~add_errorbar->proc~optional_int_to_string proc~add_hist pyplot%add_hist proc~add_hist->proc~optional_int_to_string proc~add_plot pyplot%add_plot proc~add_plot->proc~optional_int_to_string proc~add_sphere pyplot%add_sphere proc~add_sphere->proc~optional_int_to_string proc~plot_surface pyplot%plot_surface proc~plot_surface->proc~optional_int_to_string proc~plot_wireframe pyplot%plot_wireframe proc~plot_wireframe->proc~optional_int_to_string

Source Code

    subroutine integer_to_string(i, s)

    integer,          intent(in), optional  :: i     !! integer value
    character(len=*), intent(out)           :: s     !! integer value stringified

    integer :: istat !! IO status

    write(s, int_fmt, iostat=istat) i

    if (istat/=0) then
        write(error_unit,'(A)') 'Error converting integer to string'
        s = '****'
    else
        s = adjustl(s)
    end if

    end subroutine integer_to_string