Re: forall and do loop
- From: highegg <highegg@xxxxxxxxx>
- Date: Fri, 27 Jul 2007 14:14:48 -0000
On Jul 27, 3:45 pm, Tim Prince <timothypri...@xxxxxxxxxxxxx> wrote:
highegg wrote:
Use the one that appears more clear to you - easier to read and/or
write.
That appears to be the biggest advantage of forall when a mask condition
is appropriate; it's clearer than the alternatives.
Even the automatic copy (if lhs and rhs alias) is sometimes useful:
! transpose 2D array of vectors
forall(i=1:size(a,2),j=1:size(a,3)) a(:,i,j) = a(:,j,i)
.
- Follow-Ups:
- Re: forall and do loop
- From: James Van Buskirk
- Re: forall and do loop
- References:
- forall and do loop
- From: aeroguy
- Re: forall and do loop
- From: glen herrmannsfeldt
- Re: forall and do loop
- From: aeroguy
- Re: forall and do loop
- From: highegg
- Re: forall and do loop
- From: Tim Prince
- forall and do loop
- Prev by Date: Re: forall and do loop
- Next by Date: Re: How do add decoration to imported subroutines in Intel Compiler?
- Previous by thread: Re: forall and do loop
- Next by thread: Re: forall and do loop
- Index(es):
Relevant Pages
|