[Patch, fortran] PR36528 - Cray pointer to function mishandled

Paul Richard Thomas paul.richard.thomas@gmail.com
Fri Feb 13 10:55:00 GMT 2009


Hi Tobias,

> Note: This "only" fixes problem (b) but not (a) ["<<<< Unknown tree:"];

This looks very fixable but not until Monday.  The reason for it can
be seen in treepretty-print.c(print_call_name):2628.  'NIY' is
responsible for the offending message.  It comes about because
TREE_CODE (op0) == CONVERT_EXPR for this case.  This, in its turn, is
due to trans-expr.c(gfc_conv_function_val):1509, where, guess what:-)
, the cray pointer is converted to a pointer of type cray-pointee.
This needs to be done in the same way as procedure pointers; for this
case of a cray pointer to a procedure, the pointer can remain as it
is, whilst the pointee should be declared as a procedure pointer.  The
pointer should then be **assigned** to the pointee and the latter used
for the call.

Cheers

Paul



More information about the Gcc-patches mailing list