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/55855] [OOP] incorrect warning with procedure pointer component on pointer-valued base object


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

Tobias Burnus <burnus at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |burnus at gcc dot gnu.org

--- Comment #3 from Tobias Burnus <burnus at gcc dot gnu.org> 2013-01-03 11:09:02 UTC ---
(In reply to comment #1)
> The following draft patch seems to be sufficient to fix it:
> +      && rvalue->expr_type == EXPR_FUNCTION
> +      && gfc_expr_attr (rvalue).pointer)

The patch is OK (obvious) with a test case.

(In reply to comment #2)
> Adjusting title. On first glance I falsely identified 'task' as a type-bound
> procedure (although it is a procedure pointer component).

In any case, the patch (I just had tested an identical patch) fixes the issue
and also works with pointer-returning functions and TBP.


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