From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Tue, 5 Jun 2007 18:16:00 -0700 From: Roman Shaposhnick Subject: Re: [9fans] quiz In-reply-to: <2F03E7E9-C7F5-41C6-9E27-462B6B07EE14@telus.net> To: Fans of the OS Plan 9 from Bell Labs <9fans@cse.psu.edu> Message-id: <1181092560.4241.48.camel@work.sfbay.sun.com> MIME-version: 1.0 Content-type: text/plain Content-transfer-encoding: 7BIT References: <13426df10706051736q4e1852a9g3f54d8f6e2d182b4@mail.gmail.com> <2F03E7E9-C7F5-41C6-9E27-462B6B07EE14@telus.net> Topicbox-Message-UUID: 7994eb94-ead2-11e9-9d60-3106f5b1d025 On Tue, 2007-06-05 at 18:07 -0700, Paul Lalonde wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Signed bit field overflow. > > You (don't) want "unsigned int botch:1;" > > Yuck. This bit of C is even more obscure. Consider this: struct { enum {A=-1} x:1; } s = {A}; In this particular case you're at a total mercy of the compiler 'cause you can't really write '[un]signed enum' Thanks, Roman.