This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/55855] [OOP] incorrect warning with procedure pointer component on pointer-valued base object
- From: "burnus at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 03 Jan 2013 11:09:02 +0000
- Subject: [Bug fortran/55855] [OOP] incorrect warning with procedure pointer component on pointer-valued base object
- Auto-submitted: auto-generated
- References: <bug-55855-4@http.gcc.gnu.org/bugzilla/>
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.