3 use netcdf,
only: nf90_noerr, nf90_strerror
12 logical :: ncdc_enable_info = .false.
13 logical :: ncdc_enable_warn = .false.
15 logical :: ncdc_enable_info = .true.
16 logical :: ncdc_enable_warn = .true.
21 integer(i_long),
intent(in) :: status
23 if(status /= nf90_noerr)
then 29 character(len=*),
intent(in) :: err
30 #ifdef ERROR_TRACEBACK 31 integer(i_long) :: div0
34 write(*,
"(A, I0, A)") &
39 "[PROC ", cur_proc,
"]" // &
42 #ifdef ERROR_TRACEBACK 43 write(*,
"(A)")
" ** Failed to concatenate NetCDF4." 44 write(*,
"(A)")
" (Traceback requested, triggering div0 error...)" 46 write(*,
"(A)")
" Couldn't trigger traceback, ending gracefully." 47 write(*,
"(A)")
" (Ensure floating point exceptions are enabled," 48 write(*,
"(A)")
" and that you have debugging (-g) and tracebacks" 49 write(*,
"(A)")
" compiler flags enabled!)" 52 write(*,
"(A)")
" ** Failed to concatenate NetCDF4." 53 stop
" ** Failed to concatenate NetCDF4." 58 character(len=*),
intent(in) :: warn
59 if (ncdc_enable_warn) &
61 write(*,
"(A, I0, A)") &
66 "[PROC ", cur_proc,
"]" // &
68 " ** WARNING: " // warn
72 character(len=*),
intent(in) :: ifo
73 if (ncdc_enable_info) &
75 write(*,
"(A, I0, A)") &
80 "[PROC ", cur_proc,
"]" // &
86 subroutine ncdc_debug(dbg)
87 character(len=*),
intent(in) :: dbg
88 write(*,
"(A, A)")
"D: ", dbg
89 end subroutine ncdc_debug
integer, parameter, public i_long
subroutine ncdc_error(err)
subroutine ncdc_info(ifo)
subroutine ncdc_warning(warn)
subroutine ncdc_check(status)