From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Thu, 26 Nov 2015 12:37:30 +0100 From: tlaronde@polynum.com To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Message-ID: <20151126113730.GA893@polynum.com> References: <20151125160347.GN20646@sigint.cs.purdue.edu> <79F2255E-5E76-43E8-83B3-0DFB2CD34AC7@bitblocks.com> <3175949A-26D0-4C4A-BB7D-4E5A3EA7F8B7@me.com> MIME-Version: 1.0 In-Reply-To: <3175949A-26D0-4C4A-BB7D-4E5A3EA7F8B7@me.com> User-Agent: Mutt/1.5.24 (2015-08-30) Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Subject: Re: [9fans] Undefined Behaviour in C Topicbox-Message-UUID: 77a278ae-ead9-11e9-9d60-3106f5b1d025 On Thu, Nov 26, 2015 at 06:22:45AM -0500, Brantley Coile wrote: > > I thought the same thing, using ~0 for nil, but realized two things. First, that's a valid address on the PDP11 where the convention developed. It's the unibus space. Second, ~0 + member offest is still in page zero. > Plus, in C, 0 is used as a truth value for false... As long as no logical type was added but values used as logical values, the choice of 0 for "false" address is "logical" enough... -- Thierry Laronde http://www.kergis.com/ http://www.arts-po.fr/ Key fingerprint = 0FF7 E906 FBAF FE95 FD89 250D 52B1 AE95 6006 F40C