Re: Syntax Error Confusion [message #55582 is a reply to message #55487] |
Fri, 24 August 2007 20:16  |
Craig Markwardt
Messages: 1869 Registered: November 1996
|
Senior Member |
|
|
David Fanning <david@dfanning.com> writes:
> Ryan. writes:
>
>> Here is my snippet of code: (The only thing before this is some
>> declaration of variables)
>>
>> IF getdata THEN $
>> snrarray = getsnrarray(wnrange, occlist, DATESARR=time, $
>> /JULIAN, $
>> OCCS2RM=occs2rm, WAVENUMS=wavenums) && $
>>
>> occ1snr = REFORM(snrarray[0,*]) && $
>> occ2snr = REFORM(snrarray[1,*])
>
> Your problem is this is NOT the way to write a BEGIN-END
> block of code. In fact, you are forgetting the BEGIN and the END :-)
>
...
> program. Then you don't have to jump through all these
> && $ hoops to get something done.
I have a colleague who has never written a single IDL procedure or
.run'able script. He has huge snippets which he pastes directly into
the IDL window. They are all strung together with hundreds of &'s and $'s.
It is truly bizarre and unmaintainable.
However, at some point my indignation stagnated into apathy. Sigh..
Craig
--
------------------------------------------------------------ --------------
Craig B. Markwardt, Ph.D. EMAIL: craigmnet@REMOVEcow.physics.wisc.edu
Astrophysics, IDL, Finance, Derivatives | Remove "net" for better response
------------------------------------------------------------ --------------
|
|
|