(j3.2006) (SC22WG5.4130) [ukfortran] Interoperability of dummyarrays
Aleksandar Donev
adonev
Sat Nov 28 00:58:43 EST 2009
Hello,
On 11/26/2009 4:34 PM, Malcolm Cohen wrote:
> I am looking at F2003; note that 15.2.6 item (5) does not require that
> the dummy argument interoperates with the formal parameter, it merely
> requires that the formal parameter be a pointer type and that the dummy
> argument interoperates with "an entity of the referenced type".
Ah, yes, I was looking at the wrong section, thanks! Obviously array
interoperability has nothing to do with it...
>> void test(n[3], x[NPROD], y[]);
>> where NPROD must have the value n(1)*n(2)*n(3)
As Malcolm explained, this can't work because C does not have adjustible
arrays (I believe "variable length arrays" were introduced in C99 but I
am not sure they are widely supported now)---perhaps we should think
about extending interop to cover those in the future.
Aleks
--
Aleksandar Donev, Ph.D.
Luis W. Alvarez Postdoctoral Fellow
Center for Computational Sciences and Engineering (https://ccse.lbl.gov)
Lawrence Berkeley National Laboratory (http://www.lbl.gov)
E-mail: adonev at lbl.gov
Phone: (510) 486-5782 Fax: (510) 486-6900
Address: MS 50A-1148, LBL, 1 Cyclotron Rd., Berkeley, CA 94720
Web: http://cims.nyu.edu/~donev/
More information about the J3
mailing list