From: Simon Wright <simon@pushface.org>
Subject: Re: calling function but ignoring results
Date: Sat, 03 Jul 2021 20:11:05 +0100 [thread overview]
Message-ID: <lya6n32oxi.fsf@pushface.org> (raw)
In-Reply-To: 9ce930a5-d63e-4985-8371-1fc2836b554an@googlegroups.com
Gabriele Galeotti <gabriele.galeotti.xyz@gmail.com> writes:
> On Friday, July 2, 2021 at 9:32:24 AM UTC+2, amado...@gmail.com wrote:
>> On Thursday, 1 July 2021 at 19:07:43 UTC+1, Gabriele Galeotti wrote:
>> > But sometimes it is necessary...
>>
>> Yes, but the frequency is too low to justify yet another feature of
>> the language, IMO.
>
> Note: in the last reply, I am referring to the use of pragma
> Unreferenced, not a new language feature.
or aspect Unreferenced, or if you're prepared to accept GNAT extensions
anyway, just call the not-referenced variable Dummy, or Unused, or .. I
listed the relevant variable names upthread.
I suspect you _won't_ get a warning if you do reference a variable named
Dummy, but at that point it should be pretty obvious that something's
wrong.
I think any compiler needs some facility like this, at least if it has
any pretensions to interfacing to foreign languages; but it probably
won't be the same as Ada's.
next prev parent reply other threads:[~2021-07-03 19:11 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-29 19:25 calling function but ignoring results Matt Borchers
2021-06-29 19:52 ` Jeffrey R. Carter
2021-06-29 20:34 ` Dmitry A. Kazakov
2021-06-30 6:06 ` Randy Brukardt
2021-07-09 18:14 ` G.B.
2021-07-09 19:20 ` Niklas Holsti
2021-07-10 2:57 ` Randy Brukardt
2021-07-12 15:56 ` Shark8
2021-06-30 10:17 ` Luke A. Guest
2021-07-01 18:07 ` Gabriele Galeotti
2021-07-02 7:32 ` Marius Amado-Alves
2021-07-03 11:35 ` Gabriele Galeotti
2021-07-03 11:46 ` Gabriele Galeotti
2021-07-03 19:11 ` Simon Wright [this message]
2021-07-04 7:22 ` Simon Wright
2021-07-06 23:07 ` Randy Brukardt
2021-06-30 10:26 ` Luke A. Guest
2021-06-30 19:31 ` Simon Wright
2021-06-30 23:06 ` Rod Kay
2021-07-01 0:06 ` Stephen Leake
2021-07-01 3:55 ` Randy Brukardt
2021-07-03 10:42 ` Stephen Leake
2021-07-03 1:22 ` Nasser M. Abbasi
2021-07-03 4:59 ` Matt Borchers
2021-07-03 7:37 ` Gautier write-only address
2021-07-03 7:42 ` Gautier write-only address
2021-07-03 7:57 ` Niklas Holsti
2021-07-03 7:46 ` Gautier write-only address
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox