From: Adam Beneschan <adam@irvine.com>
Subject: Re: Enumeration representation clause surprise.
Date: Mon, 16 Jun 2008 07:50:19 -0700 (PDT)
Date: 2008-06-16T07:50:19-07:00 [thread overview]
Message-ID: <62644043-4704-4d49-b26b-5ba789f007a5@x1g2000prh.googlegroups.com> (raw)
In-Reply-To: wcc3ane334g.fsf@shell01.TheWorld.com
On Jun 15, 12:33 pm, Robert A Duff <bobd...@shell01.TheWorld.com>
wrote:
> Adam Beneschan <a...@irvine.com> writes:
> >...I suppose you could
> > arbitrarily decide it's zero (which would make some sense
> > mathematically)
>
> Yes, I think so.
>
> >... but it seems more commonsensical to say that nothing
> > is stored there because there ain't no bits to store anything in.
>
> But that view requires a special case.
>
> The natural unsigned range for n bits, where n >= 0,
> is 0..(2**n)-1. Which is 0..0 when n = 0.
Right, that does make sense. I'm not convinced it matters, since all
this mathematics isn't necessariliy going to be self-evident to a poor
user. This particular subthread was about a warning message that, I
think, could leave the user scratching their head about what it means,
and that isn't a good thing regardless of how sound is the mathematics
on which the warning is based.
-- Adam
next prev parent reply other threads:[~2008-06-16 14:50 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-11 11:38 Enumeration representation clause surprise Markus Schoepflin
2008-06-11 12:30 ` christoph.grein
2008-06-11 12:56 ` Markus Schoepflin
2008-06-11 13:08 ` christoph.grein
2008-06-11 13:28 ` Samuel Tardieu
2008-06-11 13:48 ` Markus Schoepflin
2008-06-11 13:56 ` Samuel Tardieu
2008-06-11 14:58 ` Adam Beneschan
2008-06-11 15:23 ` Markus Schoepflin
2008-06-12 2:37 ` Randy Brukardt
2008-06-12 2:37 ` Randy Brukardt
2008-06-11 15:56 ` Samuel Tardieu
2008-06-11 19:10 ` Adam Beneschan
2008-06-11 19:59 ` Niklas Holsti
2008-06-12 1:16 ` tmoran
2008-06-12 8:27 ` christoph.grein
2008-06-12 8:45 ` Markus Schoepflin
2008-06-12 16:43 ` Mike Silva
2008-06-12 18:41 ` Markus Schöpflin
2008-06-12 20:10 ` Mike Silva
2008-06-12 20:52 ` Simon Wright
2008-06-12 23:36 ` Mike Silva
2008-06-13 5:49 ` Simon Wright
2008-06-13 7:21 ` Keith Thompson
2008-06-13 13:31 ` Mike Silva
2008-06-13 14:45 ` Markus Schoepflin
2008-06-13 17:52 ` Keith Thompson
2008-06-13 9:14 ` Jean-Pierre Rosen
2008-06-12 19:05 ` richtmyer
2008-06-12 21:26 ` Samuel Tardieu
2008-06-12 22:42 ` Adam Beneschan
2008-06-13 7:11 ` Samuel Tardieu
2008-06-13 8:27 ` christoph.grein
2008-06-13 16:21 ` Adam Beneschan
2008-06-15 19:33 ` Robert A Duff
2008-06-16 14:50 ` Adam Beneschan [this message]
2008-06-16 19:18 ` Robert A Duff
2008-06-17 6:03 ` christoph.grein
2008-06-17 7:22 ` christoph.grein
2008-06-13 8:24 ` Peter Hermann
2008-06-13 14:47 ` Samuel Tardieu
2008-06-14 11:48 ` John B. Matthews
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox