This is the mail archive of the gcc-patches@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]

Re: [Patch, Fortran] RFC: PR fortran/37779, diagnose "missing" recursive


Tobias Burnus wrote:
Daniel Kraft wrote:
once again a slightly revised version; I converted the warnings back
to errors as suggested by Paul and Tobias.  The second change is that
I converted the calls inside resolve_actual_arglist from
resolve_procedure_expression to the general gfc_resolve_expr, so as to
"fix the problem" that this was never called for procedure actual
argument expressions.  I believe this is the cleaner solution, but I'm
also fine with using the old version of the patch instead.

No regressions on GNU/Linux-x86-32 for this one, either.
OK. Maybe it is better to change the gfc_error back to a warning as one
can indeed produce valid programs (which do some thing) using procedure
pointers.

Committed as rev 142158 with the errors converted back to warnings. I will keep the PR open and work now on the contained procedure part.


Thanks for the discussion and comments and review!

Daniel

At least for proc pointer that would be in line with Dominique's and
Jerry's preference, with James' program (see c.l.f), and I also don't
feel well rejecting valid programs. One could do it context dependent,
i.e. only reject actual arguments and warn for the rest, but that seems
to be more work, which could be deferred to a later patch (if needed).

(I checked with a couple of compilers, for actual arguments ifort and
NAG f95 give an error; for proc pointers: ifort does not support
"procptr => self" at all and NAG does not support proc pointers.  g95
(incl. proc pointer), sunf95, openf95, pgf95 and pathf95 print no
diagnostics.)

Tobias



--
Done:  Arc-Bar-Cav-Rog-Sam-Val-Wiz
To go: Hea-Kni-Mon-Pri-Ran-Tou


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