This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/54594] [OOP] Type-bound ASSIGNMENTs (elemental + array version) rejected as ambiguous
- From: "janus at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 16 Sep 2012 21:38:23 +0000
- Subject: [Bug fortran/54594] [OOP] Type-bound ASSIGNMENTs (elemental + array version) rejected as ambiguous
- Auto-submitted: auto-generated
- References: <bug-54594-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54594
--- Comment #10 from janus at gcc dot gnu.org 2012-09-16 21:38:23 UTC ---
(In reply to comment #9)
> The constraint is (F2008):
>
> C468 (R450) If generic-spec is not generic-name, each of its specific bindings
> shall have a passed-object dummy argument (4.5.4.5).
>
> with
>
> R1207 generic-spec is generic-name
> or OPERATOR ( dened-operator )
> or ASSIGNMENT ( = )
> or defined-io-generic-spec
Thanks for finding the reference. I looked in the right spot, but somehow
overread it, due to the 'indirect' wording.
I will commit the following docu-patch as obvious:
Index: gcc/fortran/resolve.c
===================================================================
--- gcc/fortran/resolve.c (revision 191364)
+++ gcc/fortran/resolve.c (working copy)
@@ -11429,7 +11429,7 @@
target_proc = target->specific->u.specific->n.sym;
gcc_assert (target_proc);
- /* All operator bindings must have a passed-object dummy argument. */
+ /* F08:C468. All operator bindings must have a passed-object dummy argument.
*/
if (target->specific->nopass)
{
gfc_error ("Type-bound operator at %L can't be NOPASS", &where);