[Patch, Fortran, F08] PR 44649: STORAGE_SIZE intrinsic

Janus Weil janus@gcc.gnu.org
Thu Jul 8 21:33:00 GMT 2010


>> However, the argument of C_SIZEOF is not optional. So the check for
>> EXPR_NULL should not be necessary, right?
>>
>
> True, though I was more thinking of something along the line
>  type(c_ptr) :: cptr
>  integer(c_intptr) :: iptr
>  write(*,*) 'pointer size:', c_sizeof(cptr), c_sizeof(iptr),
> c_sizeof(C_NULL_PTR)
>
> Actually, it seems even without thinking about optional arguments that
> should be valid - C_NULL_PTR is interoperable. I do not know how it
> shows up in check.c - probably as EXPR_VARIABLE and thus it should work
> with the patch you proposed.

Yes, it does.

I have just committed the patch as r161977.

Cheers,
Janus



More information about the Fortran mailing list