This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/49509] cannot promote types for arguments passed by value
- From: "sgk at troutmask dot apl.washington.edu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 23 Jun 2011 04:02:41 +0000
- Subject: [Bug fortran/49509] cannot promote types for arguments passed by value
- Auto-submitted: auto-generated
- References: <bug-49509-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49509
--- Comment #6 from Steve Kargl <sgk at troutmask dot apl.washington.edu> 2011-06-23 04:02:38 UTC ---
On Thu, Jun 23, 2011 at 03:01:04AM +0000, stevenj at alum dot mit.edu wrote:
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49509
>
> --- Comment #3 from stevenj at alum dot mit.edu 2011-06-23 03:00:47 UTC ---
> > Hence, the familiar old requirements of the Fortran standard are irrelevant.
> > The question is, what does the Fortran 2003 standard require for passing by
> > value, which is I believe is NEW IN FORTRAN 2003, and is SPECIFIC TO BIND(C)
> > functions.
>
> Just checked, and the VALUE attribute it is indeed new in Fortran 2003, but it
> is not specific to bind(C).
>
> But the point remains that your usual understanding of Fortran semantics does
> not apply here.
>
Sorry, but I believe the semantics do apply.
I already fixed your toy code.