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

Home » Public Forums » archive » renaming a variable without making a copy
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: renaming a variable without making a copy [message #69160 is a reply to message #68975] Fri, 11 December 2009 03:51 Go to previous messageGo to previous message
R.Bauer is currently offline  R.Bauer
Messages: 1424
Registered: November 1998
Senior Member
alx schrieb:
> On 10 d�c, 17:30, alx <lecacheux.al...@wanadoo.fr> wrote:
>> On 10 d�c, 16:36, Reimar Bauer <R.Ba...@fz-juelich.de> wrote:
>>
>>> alx schrieb:
>>> IDL> a=findgen(2,2)
>>> IDL> b=dblarr(4)
>>> IDL> reads,a,b
>>> IDL> print,b
>>> 0.0000000 1.0000000 2.0000000 3.0000000
>>> btw. just seen that reads, 1 seems to be valid, but what does it do?
>>
> Unfortunately, that does not work as you said: "reads" (cf. IDL doc)
> converts
> your 'a' array to an array of strings, then 'read' it to 'b' by using
> implicit formatting.
> That is actually not a "memory read" and, likely, does not work with
> structures.
>
>

what is that doing then?

IDL> a=bindgen(3)
IDL> b=ptr_new({s:intarr(3)})
IDL> reads,a,*b
IDL> print,*b
{ 0 1 2
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Vectorize procedure
Next Topic: array subscripting problem

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

Current Time: Fri Oct 10 06:15:09 PDT 2025

Total time taken to generate the page: 1.28084 seconds