Hello,
On 2008-05-01 16:29:55 -0400, Bil Kleb <Bil.Kleb@[EMAIL PROTECTED]
> said:
>
> integer :: nblocks_dum ! position holder for read
>
> [..]
>
> read(8) nblocks_dum, other, useful, data
>
> due to reading files we have no control over. As we don't
> need nblocks_dum, this produces a "set but never used"
> warning for nblocks_dum.
You might try
Tabbing past the input field, if the format has a specified width.
( i10, 3e20.10) --> ( 10X, 4e20.10)
(Obviously, this fails with list-directed i/o,
where there's no set width.)
or
Read the line into a character string, remove the offending field,
and use an internal read to get the rest.
read( 8, '( a)') line_from_file
line_from_file = line_from_file( 11: )
read( line_from_file, '( some format)') other, useful, data
or
(As Richard suggested) put the variable in common or a module,
or passing it to an very (read: 'separately compiled') external procedure.
call eat_dum( nblocks_dum) ! who knows what evil lurks in eat_dum() ?
HTH
--
Cheers!
Dan Nagle


|