[daip] silly error

Eric Greisen egreisen at nrao.edu
Thu Nov 21 17:13:06 EST 2013


Lawrence Rudnick wrote:
> Eric -
> 
> I am making some silly error in a run file, but can't see it.  here's 
> the offending commands in the run file
> 
>  $  GET THE APPROPRIATE UV FILE
>     type ' '; type 'enter indisk, catno:'
>     read i
>     read j
>     indi i; getn j
>     in3na= inna
> 
> here's the AIPS output
> 
> AIPS 1: $
> AIPS 1: $  GET THE APPROPRIATE UV FILE
> AIPS 1:  type ' '; type 'ENTER INDISK, CATNO:'
> AIPS 1: ' '
> AIPS 1: 'ENTER INDISK, CATNO:'
> AIPS 1:  read i
> AIPS 1: NUMBER SIZE
> 
> so it's acting as if I'd entered something illegal, when i haven't typed 
> anything on the screen.   these commands are not inside a procedure.

The issue is where does the READ read from.  It reads from the same 
input device as caused the READ to be issued - i.e. your script text 
file.  Not very useful, but how else to resolve the issue?  A READ in a 
proc reads from the terminal or script that invokes the proc, not 
whatever defined the proc.  That is more useful and is the only good way 
to use READ.  I have added to the READ help file.

thanks

Eric Greisen




More information about the Daip mailing list