public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/44962] New: [OOP] ICE with specification expression SIZE(<CLASS>)
@ 2010-07-16 8:50 burnus at gcc dot gnu dot org
2010-07-18 16:17 ` [Bug fortran/44962] " janus at gcc dot gnu dot org
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: burnus at gcc dot gnu dot org @ 2010-07-16 8:50 UTC (permalink / raw)
To: gcc-bugs
Reported by bd satish at http://gcc.gnu.org/ml/fortran/2010-07/msg00206.html
The following program segfaults. The crucial part is that the argument has is
CLASS and not TYPE - and that it is used in a specification expression.
The ICE occurs when it is written to the .MOD file.
Valgrind shows:
==15819== Invalid read of size 8
==15819== at 0x50E636: mio_expr (module.c:3091)
==15819== by 0x50F0C9: mio_array_spec (module.c:2179)
==15819== by 0x50F208: mio_component (module.c:2371)
==15819== by 0x50F3E7: mio_symbol (module.c:2420)
==15819== by 0x50F82A: write_symbol (module.c:4804)
==15819== by 0x510CE5: write_symbol0 (module.c:4844)
==15819== by 0x51132B: gfc_dump_module (module.c:5022)
==15819== by 0x51BFE0: gfc_parse_file (parse.c:4388)
module array
type :: t_array
real, dimension(10) :: coeff
contains
procedure, nopass :: get_coeff
end type t_array
contains
function get_coeff(self) result(coeff)
class(t_array), intent(in) :: self
real, dimension(5) :: coeff
i = size(self%coeff)
end function get_coeff
end module array
--
Summary: [OOP] ICE with specification expression SIZE(<CLASS>)
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: burnus at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44962
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/44962] [OOP] ICE with specification expression SIZE(<CLASS>)
2010-07-16 8:50 [Bug fortran/44962] New: [OOP] ICE with specification expression SIZE(<CLASS>) burnus at gcc dot gnu dot org
@ 2010-07-18 16:17 ` janus at gcc dot gnu dot org
2010-07-29 20:59 ` janus at gcc dot gnu dot org
2010-07-29 21:01 ` janus at gcc dot gnu dot org
2 siblings, 0 replies; 4+ messages in thread
From: janus at gcc dot gnu dot org @ 2010-07-18 16:17 UTC (permalink / raw)
To: gcc-bugs
--
janus at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |janus at gcc dot gnu dot org
|dot org |
Status|UNCONFIRMED |ASSIGNED
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2010-07-18 16:17:11
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44962
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/44962] [OOP] ICE with specification expression SIZE(<CLASS>)
2010-07-16 8:50 [Bug fortran/44962] New: [OOP] ICE with specification expression SIZE(<CLASS>) burnus at gcc dot gnu dot org
2010-07-18 16:17 ` [Bug fortran/44962] " janus at gcc dot gnu dot org
@ 2010-07-29 20:59 ` janus at gcc dot gnu dot org
2010-07-29 21:01 ` janus at gcc dot gnu dot org
2 siblings, 0 replies; 4+ messages in thread
From: janus at gcc dot gnu dot org @ 2010-07-29 20:59 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from janus at gcc dot gnu dot org 2010-07-29 20:59 -------
Subject: Bug 44962
Author: janus
Date: Thu Jul 29 20:58:57 2010
New Revision: 162695
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=162695
Log:
2010-07-29 Janus Weil <janus@gcc.gnu.org>
PR fortran/44962
* resolve.c (resolve_fl_derived): Call gfc_resolve_array_spec.
2010-07-29 Janus Weil <janus@gcc.gnu.org>
PR fortran/44962
* gfortran.dg/typebound_proc_17.f03: New.
Added:
trunk/gcc/testsuite/gfortran.dg/typebound_proc_17.f03
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/resolve.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44962
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug fortran/44962] [OOP] ICE with specification expression SIZE(<CLASS>)
2010-07-16 8:50 [Bug fortran/44962] New: [OOP] ICE with specification expression SIZE(<CLASS>) burnus at gcc dot gnu dot org
2010-07-18 16:17 ` [Bug fortran/44962] " janus at gcc dot gnu dot org
2010-07-29 20:59 ` janus at gcc dot gnu dot org
@ 2010-07-29 21:01 ` janus at gcc dot gnu dot org
2 siblings, 0 replies; 4+ messages in thread
From: janus at gcc dot gnu dot org @ 2010-07-29 21:01 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from janus at gcc dot gnu dot org 2010-07-29 21:01 -------
Fixed with r162695. Closing.
--
janus at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44962
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-07-29 21:01 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-16 8:50 [Bug fortran/44962] New: [OOP] ICE with specification expression SIZE(<CLASS>) burnus at gcc dot gnu dot org
2010-07-18 16:17 ` [Bug fortran/44962] " janus at gcc dot gnu dot org
2010-07-29 20:59 ` janus at gcc dot gnu dot org
2010-07-29 21:01 ` 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).