[Xcb] Iter

Jamey Sharp jamey at minilop.net
Sat Dec 17 16:34:39 PST 2005


On Sat, Dec 17, 2005 at 06:56:23PM -0500, Jeremy Kolb wrote:
> I feel like we should either provide both or just use the iterators
> interface.  It's kind of confusing.

Note that some lists *don't* get iterators, because they're primitive
types -- all the strings are array-access only, for example. So there
are three categories: array-only, iterator-only, and both.

Yes, maybe that is a bit confusing. But when they're available arrays
are so convenient under many circumstances, and I expect if we take them
away people are going to start pretending that the pointer inside the
iterator is actually an array, and then they're going to do that for
types where that doesn't work, and that'll be even more confusing. At
least this way you get a compile-time error if you try to use an access
method that isn't available.

--Jamey
-------------- 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/20051217/aa1b4796/attachment.pgp


More information about the Xcb mailing list