comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Program to convert (i) to [i] ?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Program to convert (i) to [i] ? [message #73700 is a reply to message #73560] Sat, 20 November 2010 11:27 Go to previous messageGo to previous message
wlandsman is currently offline  wlandsman
Messages: 743
Registered: June 2000
Senior Member
On Nov 19, 4:27 pm, "M. Katz" <MKatz...@yahoo.com> wrote:

>
> Someone mentioned a program that could intelligently convert code en
> masse, but I cannot now find that reference. Can anyone point me in
> the correct direction, or share their experience with using it?

The program idlv4_to_v5 is in http://idlastro.gsfc.nasa.gov/ftp/contrib/landsman/v5/
. See the README file there.

> How
> does it know which of your labels are your own .pro functions and
> which are variable names when there is an ambiguity?

It uses RESOLVE_ROUTINE and ROUTINE_INFO to make a list of available
functions for the current !PATH. It then assumes that any
function_or_variable() is a function if it is in this list, and
otherwise is a variable. So it resolves the ambiguity the same way
the IDL session would (though not necessarily the way the user
intended).

The program does sometimes have problems with parentheses written
within quotes, or with parentheses split among multiple line, but it
usually gives a warning when it gets confused. So a few procedures
required further manual editing.

Disclaimer: I was quite happy with the effectiveness of this procedure
when I used it, but I haven't used it in many years. -Wayne
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Correct Image Resizing -- New Coyote Program
Next Topic: IDL 8.0.1 ARG_PRESENT question

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:03:53 PDT 2025

Total time taken to generate the page: 0.00403 seconds