public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/43207] [OOP] invalid pointer assignment => type%parent
[not found] <bug-43207-4@http.gcc.gnu.org/bugzilla/>
@ 2012-11-07 22:01 ` janus at gcc dot gnu.org
2012-11-07 22:26 ` janus at gcc dot gnu.org
2012-11-08 9:26 ` janus at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: janus at gcc dot gnu.org @ 2012-11-07 22:01 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43207
--- Comment #9 from janus at gcc dot gnu.org 2012-11-07 22:00:40 UTC ---
(In reply to comment #8)
> r159431 fixes the ICE. Comment #0 is now accepted without an error message.
With 4.7 and trunk, comment #0 is rejected with:
this_parent => this%parent ! <<<<<<<<<<<<
1
Error: Pointer assignment target is neither TARGET nor POINTER at (1)
However, comment #1 is still accepted without error message.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/43207] [OOP] invalid pointer assignment => type%parent
[not found] <bug-43207-4@http.gcc.gnu.org/bugzilla/>
2012-11-07 22:01 ` [Bug fortran/43207] [OOP] invalid pointer assignment => type%parent janus at gcc dot gnu.org
@ 2012-11-07 22:26 ` janus at gcc dot gnu.org
2012-11-08 9:26 ` janus at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: janus at gcc dot gnu.org @ 2012-11-07 22:26 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43207
--- Comment #10 from janus at gcc dot gnu.org 2012-11-07 22:26:18 UTC ---
Here is a draft patch which rejects comment #1:
Index: gcc/fortran/primary.c
===================================================================
--- gcc/fortran/primary.c (revision 193296)
+++ gcc/fortran/primary.c (working copy)
@@ -2104,6 +2104,13 @@ check_substring:
}
}
+ /* F03:C611. */
+ if (primary->ts.type == BT_DERIVED && primary->ts.u.derived->attr.abstract)
+ {
+ gfc_error ("Nonpolymorphic reference to abstract type at %C");
+ return MATCH_ERROR;
+ }
+
/* F2008, C727. */
if (primary->expr_type == EXPR_PPC && gfc_is_coindexed (primary))
{
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/43207] [OOP] invalid pointer assignment => type%parent
[not found] <bug-43207-4@http.gcc.gnu.org/bugzilla/>
2012-11-07 22:01 ` [Bug fortran/43207] [OOP] invalid pointer assignment => type%parent janus at gcc dot gnu.org
2012-11-07 22:26 ` janus at gcc dot gnu.org
@ 2012-11-08 9:26 ` janus at gcc dot gnu.org
2 siblings, 0 replies; 4+ messages in thread
From: janus at gcc dot gnu.org @ 2012-11-08 9:26 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43207
--- Comment #11 from janus at gcc dot gnu.org 2012-11-08 09:25:39 UTC ---
(In reply to comment #10)
> Here is a draft patch which rejects comment #1:
This shows one testsuite failure:
FAIL: gfortran.dg/abstract_type_3.f03 -O (test for errors, line 44)
FAIL: gfortran.dg/abstract_type_3.f03 -O (test for excess errors)
where it correctly triggers on this line:
arg = again_abst_t () ! { dg-error "Can't construct ABSTRACT type 'again_ab
1
Error: Nonpolymorphic reference to abstract type at (1)
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/43207] [OOP] invalid pointer assignment => type%parent
2010-02-28 8:09 [Bug fortran/43207] New: [OOP] ICE for " burnus at gcc dot gnu dot org
@ 2010-05-15 14:08 ` janus at gcc dot gnu dot org
0 siblings, 0 replies; 4+ messages in thread
From: janus at gcc dot gnu dot org @ 2010-05-15 14:08 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from janus at gcc dot gnu dot org 2010-05-15 14:08 -------
r159431 fixes the ICE. Comment #0 is now accepted without an error message.
--
janus at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords|ice-on-valid-code |accepts-invalid
Summary|[OOP] ICE for class pointer |[OOP] invalid pointer
|=> null() initialization |assignment => type%parent
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43207
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2012-11-08 9:26 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-43207-4@http.gcc.gnu.org/bugzilla/>
2012-11-07 22:01 ` [Bug fortran/43207] [OOP] invalid pointer assignment => type%parent janus at gcc dot gnu.org
2012-11-07 22:26 ` janus at gcc dot gnu.org
2012-11-08 9:26 ` janus at gcc dot gnu.org
2010-02-28 8:09 [Bug fortran/43207] New: [OOP] ICE for " burnus at gcc dot gnu dot org
2010-05-15 14:08 ` [Bug fortran/43207] [OOP] " janus at gcc dot gnu dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).