@@ -281,7 +281,7 @@ module json_module
281
281
! program test
282
282
! use json_module
283
283
! implicit none
284
- ! type(json_value),pointer :: p
284
+ ! type(json_value),pointer :: p
285
285
! call json_initialize() !initialize the module
286
286
! call json_create_object(p,'') !create the root
287
287
! call json_add(p,'year',1805) !add some data
@@ -440,16 +440,16 @@ module json_module
440
440
! Structure constructor to initialize a [[json_file(type)]] object
441
441
! with an existing [[json_value]] object
442
442
!
443
- ! # Example
443
+ ! # Example
444
444
!
445
- ! ```fortran
445
+ ! ```fortran
446
446
! ...
447
447
! type(json_file) :: my_file
448
448
! type(json_value) :: json_object
449
449
! ...
450
450
! ! Construct a json_object
451
451
! my_file = json_file(json_object)
452
-
452
+ ! ```
453
453
interface json_file
454
454
module procedure initialize_json_file
455
455
end interface
@@ -924,8 +924,11 @@ end subroutine array_callback_func
924
924
! Cast a [[json_value]] object as a [[json_file(type)]] object
925
925
926
926
function initialize_json_file (p ) result(file_object)
927
- type (json_value), pointer , optional , intent (in ) :: p
928
- ! ! `json_value` object to cast as a `json_file` object
927
+
928
+ implicit none
929
+
930
+ type (json_value), pointer , optional , intent (in ) :: p ! ! `json_value` object to cast
931
+ ! ! as a `json_file` object
929
932
type (json_file) :: file_object
930
933
931
934
if (present (p)) file_object% p = > p
@@ -936,7 +939,7 @@ end function initialize_json_file
936
939
! *****************************************************************************************
937
940
! > author: Jacob Williams
938
941
!
939
- ! Destroy the data within a [[json_value]], and rest type to json_unknown.
942
+ ! Destroy the data within a [[json_value]], and rest type to ` json_unknown` .
940
943
941
944
subroutine destroy_json_data (d )
942
945
@@ -1284,6 +1287,8 @@ end subroutine json_file_get_object
1284
1287
! date: 7/23/2015
1285
1288
!
1286
1289
! Get a [[json_value]] pointer to the JSON file root.
1290
+ !
1291
+ ! @note This is equivalent to calling ```[[json_file]]%get('$',p)```
1287
1292
1288
1293
subroutine json_file_get_root (me ,p )
1289
1294
0 commit comments