HP Fortran Programmer's Reference (September 2007)
HP Fortran statements
POINTER (Cray-style extension)
Chapter 10 427
IF (p.EQ.0) THEN
PRINT *, 'MALLOC failed.'
ELSE
DO i = 1,nelem
iarr(i) = i
END DO
PRINT *, (iarr(i),i=1,nelem)
CALL FREE( p )
ENDIF
RETURN
END SUBROUTINE print_iarr
Related statements
POINTER (standard Fortran 90)
Related concepts
For related information, see the following:
• “Pointers” on page 131
• The description of the LOC routine in Table 12-3
• The descriptions of the MALLOC and FREE intrinsics in Chapter 11, “Intrinsic procedures,”
on page 501