Google
 

Trailing-Edge - PDP-10 Archives - BB-4157F-BM_1983 - fortran/test/image.for
There are 11 other files named image.for in the archive. Click here to see a list.
	PROGRAM IMAGE

! This software is furnished under a license and may only be used
! or copied in accordance with the terms of such license.

! Copyright (C) Digital Equipment Corporation 1981, 1983

!	Version 7	IMAGE.FOR

!	Basic IMAGE I/O test.

	DOUBLE PRECISION D,DD

!	Data to be written out.

	I=1234; X=456.789; D=123456789.0123

!	OPEN with MODE= and ACCESS= specified.

	OPEN(22,MODE='IMAGE',ACCESS='SEQOUT')
300	WRITE(22) I,X,D
	CLOSE(22)
	OPEN(22,MODE='IMAGE',ACCESS='SEQIN')
	READ(22) II,XX,DD
	IF (I.NE.II) TYPE 310,I,II
	IF (X.NE.XX) TYPE 320,X,XX
	IF (D.NE.DD) TYPE 330,D,DD

310	FORMAT(' ?Error line 300.  IMAGE I/O.',/
	1	'  I='I' II='I)
320	FORMAT(' ?Error line 300.  IMAGE I/O.',/
	1	'  X='F' XX='F)
330	FORMAT(' ?Error line 300.  IMAGE I/O.',/
	1	'  D='D' DD='D)
	CLOSE(22)

	STOP
	END