From: Julian Leyh <julian@vgai.de>
Subject: Re: Syntax of extended return statement
Date: Wed, 16 Mar 2011 03:28:56 -0700 (PDT)
Date: 2011-03-16T03:28:56-07:00 [thread overview]
Message-ID: <eda59858-8e2a-4deb-9093-0a4fdd4b5de4@d26g2000prn.googlegroups.com> (raw)
In-Reply-To: C9A5AE3D.82B0%news@findlayw.plus.com
On 16 Mrz., 01:01, Bill Findlay <n...@findlayw.plus.com> wrote:
> I have the following compilation warning from GNAT:
>
> function pop
> return KDF9.word is
> begin
> the_nest_depth := the_nest_depth - 1;
> return result : KDF9.word := the_nest(the_nest_depth) do
> |>>> warning: "result" is not modified, could be declared constant
>
> the_nest(the_nest_depth) := 0;
> end return;
> end pop;
"result" is not modified, so the warning is correct.
prev parent reply other threads:[~2011-03-16 10:28 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-16 0:01 Syntax of extended return statement Bill Findlay
2011-03-16 2:23 ` Robert A Duff
2011-03-16 17:03 ` Bill Findlay
2011-03-16 10:28 ` Julian Leyh [this message]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox