(j3.2006) (j3.2005) allocate / assignment

Bill Long longb
Tue Nov 28 19:26:01 EST 2006



Aleksandar Donev wrote:

>On Tuesday 28 November 2006 16:09, Bill Long wrote:
>  
>
>>ALLOCATE(NEW, SOURCE=OLD)
>>Is the effect of the allocate statement any different (assuming NEW is
>>unallocated before) from this assignment?
>>NEW = OLD
>>    
>>
>I believe they are identical. We only added "polymorphic assignment" for 
>allocatables recently---in F2003 the rhs could not be polymorphic. So one had 
>to use SOURCE=.
>  
>

Actually, I think it was the lhs (the <variable>) that could not be 
polymorphic in f03. 

Cheers,
Bill


-- 
Bill Long                                   longb at cray.com
Fortran Technical Support    &              voice: 651-605-9024
Bioinformatics Software Development         fax:   651-605-9142
Cray Inc., 1340 Mendota Heights Rd., Mendota Heights, MN, 55120

            

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://j3.scs.gmu.edu/pipermail/j3/attachments/20061128/253de2e1/attachment.html 



More information about the J3 mailing list