home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.fortran
- Path: sparky!uunet!charon.amdahl.com!pacbell.com!sgiblab!sdd.hp.com!hp-col!hpfcnfs.sde.hp.com!pld
- From: pld@fc.hp.com (Paul_Dineen)
- Subject: Re: unformatted output: << SUMMARY >>
- Message-ID: <BxB3rw.KEy@fc.sde.hp.com>
- Sender: news@fc.sde.hp.com (Notes Administrator)
- Organization: HP CLO/CoLL, Fort Collins, CO
- X-Newsreader: TIN [version 1.1.4 PL6]
- References: <1992Nov5.111303.17921@uts.uni-c.dk>
- Date: Fri, 6 Nov 1992 18:09:31 GMT
- Lines: 39
-
- In article 26525@chpc.utexas.edu, michael@chpc.utexas.edu (Michael Lemke) writes:
- >Doesn't have the record *number* to be stored at some place as well?
- >Nothing stops you from doing
- >
- > open( ,.... access='direct', .... )
- > write( ..., rec=777 ) data
- > write( ..., rec=32 ) mode_data
- > close( ... )
- >
- >which gives you just two records of data and lots of `holes'. Or am I
- >missing something?
-
- No. You get holes. For example, using HP Fortran on a 9.0 9000/750:
-
- $ cat dw.f
- open(10,file='holes',access='direct',recl=8)
- write(10,rec=1000) 1, 2
- i = 0
- j = 0
- read(10,rec=1000) i, j
- print *, i, j
- end
-
- $ f77 dw.f
- dw.f:
- MAIN:
-
- $ a.out
- 1 2
-
- $ ll holes
- -rw-rw-r-- 1 pld users 8000 Nov 6 11:06 holes
-
- $ od -c holes
- 0000000 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0
- *
- 0017460 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 001 \0 \0 \0 002
- 0017500
-
-