This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: [PATCH] fortran/41918 -- silence a warning
- From: Tobias Burnus <burnus at net-b dot de>
- To: Steve Kargl <sgk at troutmask dot apl dot washington dot edu>
- Cc: fortran at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Wed, 04 Nov 2009 08:25:09 +0100
- Subject: Re: [PATCH] fortran/41918 -- silence a warning
- References: <20091103230148.GA19411@troutmask.apl.washington.edu>
Am 04.11.2009 00:01, schrieb Steve Kargl:
> The patch has been built and regtested on x86_64-*-freebsd.
> There are no regression. I'm not sure if this will silence
> all possible warnings where a default initialization can
> occur, but it catches those in my tet program.
>
+ if (!(sym->ts.type == BT_DERIVED
+ && sym->ts.u.derived->components->initializer))
+ gfc_warning ("Dummy argument '%s' at %L was declared INTENT(OUT) "
Looks OK. Richard Maine would probably also add a check for "alloc_comp" as he sees the automatic deallocation also as a kind of assignment. I am not sure whether this sensible or not.
Tobias