[Xcb] XCB naming conventions

Jamey Sharp jamey at minilop.net
Wed Sep 13 14:48:08 PDT 2006

On Wed, Sep 13, 2006 at 02:13:36PM -0700, Ian Osgood wrote:
> Also, we currently have three aliases for a byte: CARD8, BYTE, and
> BOOL. I propose dropping BYTE, and naming the others uint8_t and
> bool8_t. (Having a separate boolean type conveys range information,
> and the name distinguishes it from other boolean types whose size is
> incompatible or undefined.)

AFAICT, there's no bool8_t defined in C99. stdbool.h provides a 'bool'
type, but I don't see any specification of what size that type is.

So bool8_t would be an XCB-specific type, and would have to be
namespaced as such: 'xcb_bool8_t'. But in that case, I think it should
just be named after the protocol spec: 'xcb_bool_t'.

While I agree that range information is good, I think using a
non-standard type here would be more confusing than helpful. When we
have XCB's API documented using the protocol specification text, I think
the range will be sufficiently clear.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.freedesktop.org/archives/xcb/attachments/20060913/71024638/attachment.pgp

More information about the Xcb mailing list