@@ -144,7 +144,15 @@ subroutine test_46(error_cnt)
144
144
error_cnt = error_cnt + 1
145
145
end if
146
146
147
+ ! now, we try them when an exception is active:
148
+ call json% get(p, CK_' not_there' , ival) ! this will raise an exception
149
+ call json% get(p, CK_' not_there' , rval, found, default= 99.0_RK )
150
+ call json% get(p, CK_' not_there' , cvec, found, default= [CK_' 1' ])
151
+ call json% get(p, CK_' not_there' , cvec2, ilen, found, default= cvec_default)
152
+ call json% get(p, CK_' not_there' , cvec2, ilen, found, default= cvec_default, default_ilen= ilen_default)
153
+
147
154
call json% destroy(p)
155
+ call json% destroy()
148
156
149
157
!- --------------------------------
150
158
! now, json_file routines:
@@ -234,6 +242,13 @@ subroutine test_46(error_cnt)
234
242
error_cnt = error_cnt + 1
235
243
end if
236
244
245
+ ! now, we try them when an exception is active:
246
+ call json_f% get(CK_' not_there' , ival) ! this will raise an exception
247
+ call json_f% get(CK_' not_there' , rval, found, default= 99.0_RK )
248
+ call json_f% get(CK_' not_there' , cvec, found, default= [CK_' 1' ])
249
+ call json_f% get(CK_' not_there' , cvec2, ilen, found, default= cvec_default)
250
+ call json_f% get(CK_' not_there' , cvec2, ilen, found, default= cvec_default, default_ilen= ilen_default)
251
+
237
252
if (error_cnt== 0 ) then
238
253
write (error_unit,' (A)' ) ' Success!'
239
254
else
0 commit comments