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

Home » Public Forums » archive » Modifying Arrays and Structures in HASH's (hint: you can't)
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: Modifying Arrays and Structures in HASH's (hint: you can't) [message #85364 is a reply to message #85348] Mon, 29 July 2013 07:34 Go to previous messageGo to previous message
Bob[4] is currently offline  Bob[4]
Messages: 24
Registered: April 2009
Junior Member
On Sunday, July 28, 2013 1:32:25 PM UTC-6, fawltyl...@gmail.com wrote:
> On Sunday, July 28, 2013 6:13:18 AM UTC+2, bobnn...@gmail.com wrote:
>
>
>
>> I will say that the inability of accessing directly into hashes and lists (by reference, not copy) is so disappointing that I am moving away from IDL. So if you found a way around this it would be very nice.
>
>
>
> LIST is a pointer array in disguise. You can get a copy of this array and manipulate list elements directly:
>
>
>
> IDL> l=list(1,2,3)
>
> IDL> a=l.idl_container::get(/all)
>
> IDL> print, l
>
> 1
>
> 2
>
> 3
>
> IDL> *a[1]=123
>
> IDL> print, l
>
> 1
>
> 123
>
> 3
>
>
>
> regards,
>
> Lajos

That is nice, but it is really for hashes that I want this behavior. This trick does not work for them.

As an aside I saw a list of future IDL features and Dictionary type was on it. Lets hope that this is implemented correctly and not with the crippled operator overloading system in IDL (like hash is).

Bob
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Does anyone have any experience with using SciDB with IDL (or any other language)?
Next Topic: Find all user-defined structure definitions

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

Current Time: Fri Oct 10 11:06:21 PDT 2025

Total time taken to generate the page: 2.32698 seconds