This patch does the first minor steps towards TR 29113: It accepts the OPTIONAL attribute in procedures with C binding. As gfortran already passes absent arguments a NULL pointer, there is no changed needed, except in the diagnostics part. Additionally, it is a feature also supported by other compilers. Additionally, this patch adds the option -std=f2008tr (tr = Technical Report(s)), which is supposed to cover Fortran 2008 and the two technical reports, TR 29113 (further interop with C) and the TR about enhanced coarray support. I think it would be nice if TYPE(*) and DIMENSION(..) could also be implemented during the 4.7 development period as they are useful for C interoperability ("void *buffer") - and in particular for MPI 3; additionally, they do not seem to be that difficult to implement. However, I do not plan to work on them in the near future. Build and regtested on x86-64-linux OK for the trunk? The implementation status will be tracked at http://gcc.gnu.org/wiki/TR29113Status ;-) Tobias PS: I included in the patch also a patchlet for IMPORT, cf. Mikael's comment at http://gcc.gnu.org/ml/fortran/2011-05/msg00005.html; with that patch, "sym" is always set to NULL when entering the loop for the next symbol. I think it is not really needed as "gfc_current_ns->parent" should be always "!= NULL", but maybe one manages have it NULL.