Skip to content

Commit 6fefa64

Browse files
jalveszjvdp1
andauthored
Update doc/specs/stdlib_str2num.md
Co-authored-by: Jeremie Vandenplas <[email protected]>
1 parent 2954856 commit 6fefa64

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

doc/specs/stdlib_str2num.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,10 @@ program example_str2num
7979
use stdlib_str2num, only: to_num_p
8080
character(:), allocatable, target :: chain
8181
character(len=:), pointer :: cptr
82-
real(dp), allocatable :: r(:)
82+
real(dp) :: r(6)
8383
integer :: i
8484
8585
chain = " 1.234 1.E1 1e0 0.1234E0 12.21e+001 -34.5E1"
86-
allocate( r(6) )
8786
cptr => chain
8887
do i =1, 6
8988
r(i) = to_num_p( cptr , r(i) ) !> the cptr pointer is shifted within the function

0 commit comments

Comments
 (0)