This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/40054] [F08] Pointer functions as lvalue


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40054

--- Comment #7 from janus at gcc dot gnu.org 2011-07-03 15:43:39 UTC ---
I think it will be very hard (if not impossible) to implement this, while
maintaining support for statement functions at the same time. In particular,
how is one supposed to interpret a statement like:

f (x) = x + 1

Is this a statement function declaration? Or rather an assignment to the result
of a pointer-valued function f, which is defined further down the road? In many
situations this seems to be indistinguishable (or one can only decide it at
resolution stage, where the function f has been parsed already, if it is
there). Or am I missing some restriction in the standard?

In any case, statement functions are obsolescent since F95, so would it be an
option to not support them with -std=f2008?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]