public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "burnus at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/47463] [OOP] ICE in gfc_add_component_ref
Date: Mon, 31 Jan 2011 12:08:00 -0000	[thread overview]
Message-ID: <bug-47463-4-2COCwjsxBC@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-47463-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #6 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-01-31 11:03:31 UTC ---
(In reply to comment #5)
> hydro_flow.f90:55.13:
>     call this%init(st, gr)
>              1
> Error: Found no matching specific binding for the call to the GENERIC
> 'init' at (1)

That matches Cray's ftn (cf. comment 1):
    call this%init(st, gr)
             ^             
ftn-389 crayftn: ERROR INIT_PARAMS, File = hydro_flow.f90, Line = 55, Column =
14 
  No specific match can be found for the generic subprogram call "INIT".



> Changing this generic call to the corresponding specific type-bound procedure,

I assume s/this%init/this%init_comps/ in that line. With Crayftn I then get the
following, which looks at a glance like a bug in crayftn, though I have not
checked it:

     procedure :: init_comps
                  ^
ftn-1130 crayftn: ERROR HYDRO_FLOW, File = hydro_flow.f90, Line = 21, Column =
19
  "INIT_COMPS" is specified as a procedure-name in a type bound procedure
statement.  It must be a module procedure or an external procedure with an
explicit interface.

  subroutine init_comps (this, st, gr)
             ^
ftn-575 crayftn: ERROR HYDRO_FLOW, File = hydro_flow.f90, Line = 66, Column =
14
  "INIT_COMPS" has been used as a subroutine, therefore it must not be declared
as a module procedure subroutine.


> I get:
[ Some gfortran error message, completely different from Crays]


> And the same without type-binding:
>     call init_comps(this, st, gr)
> Error: Type mismatch in argument 'this' at (1); passed CLASS(flow_t) to
> CLASS(grid_t)

That version works with Crayftn. It then compiles hydro_flow.f90 - and stops in
hydro_recon.f90 (line 31) for "fl%n" as '"N" is not a component of derived type
"FLOW_T"'


  parent reply	other threads:[~2011-01-31 11:03 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-25 19:33 [Bug fortran/47463] New: " townsend at astro dot wisc.edu
2011-01-25 20:33 ` [Bug fortran/47463] [OOP] " burnus at gcc dot gnu.org
2011-01-25 20:53 ` mikael at gcc dot gnu.org
2011-01-27  5:33 ` townsend at astro dot wisc.edu
2011-01-30 16:01 ` janus at gcc dot gnu.org
2011-01-31 10:48 ` janus at gcc dot gnu.org
2011-01-31 12:08 ` burnus at gcc dot gnu.org [this message]
2011-01-31 15:13 ` janus at gcc dot gnu.org
2011-01-31 18:46 ` janus at gcc dot gnu.org
2011-01-31 21:53 ` burnus at gcc dot gnu.org
2011-02-02 18:25 ` dnovillo at gcc dot gnu.org
2011-02-09 18:11 ` janus at gcc dot gnu.org
2011-02-09 18:58 ` burnus at gcc dot gnu.org
2011-02-09 20:24 ` janus at gcc dot gnu.org
2011-02-09 20:35 ` janus at gcc dot gnu.org
2011-02-09 20:49 ` janus at gcc dot gnu.org
2011-02-09 21:10 ` burnus at gcc dot gnu.org
2011-02-10  6:25 ` paul.richard.thomas at gmail dot com

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-47463-4-2COCwjsxBC@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).