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

Home » Public Forums » archive » Is it an IDL bug or feature?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Is it an IDL bug or feature? [message #5249] Wed, 25 October 1995 00:00
Liyun Wang is currently offline  Liyun Wang
Messages: 4
Registered: October 1995
Junior Member
Hi,

In a process of debugging our IDL codes, we found an interesting case which you
may want to be aware of. Consider this:

IDL> b = 1
IDL> a = b(1,2,1)

IDL will complain about subscript being out of range. But watch this:

IDL> b = 1
IDL> a = b([2],[1],[2])
or
IDL> a = b([[2],[1],[10],[30]])
or even
IDL> a = b([[2],[,1],[10],[30]], [[20],[12],[70],[20]])

What do you think IDL will respond? Will it issue a syntax error message?
Wrong! As long as the subscript indices of a *scalar* variable, like b here,
are arrays with the same dimension, IDL does not care nor complain, no matter
how
many array elements you give. Do you consider this to be a potential bug or a
feature of IDL?

--
============================================================ =========
Liyun Wang | Voice: 301-286-3126
G1 Building 26, SOHO EAF | FAX: 301-286-0264
NASA, GSFC, Code 682.3 | Liyun.Wang.1@gsfc.nasa.gov
Greenbelt, MD 20771 |http://orpheus.nascom.nasa.gov/~lwang
============================================================ =========
[Message index]
 
Read Message
Previous Topic: What is the status of beta version of PV-Wave for Windows?
Next Topic: CALL_EXTERNAL under OpenVMS Alpha (IDL 4.0.1)

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

Current Time: Fri Oct 10 05:51:14 PDT 2025

Total time taken to generate the page: 0.08226 seconds