19 Aug 08:59
Re: The problem isn't C's integer philosophy; it's your design. (was: size_type doubts / integer library..)
From: Zeljko Vrba <zvrba <at> ifi.uio.no>
Subject: Re: The problem isn't C's integer philosophy; it's your design. (was: size_type doubts / integer library..)
Newsgroups: gmane.comp.lib.boost.user
Date: 2008-08-19 06:59:25 GMT
Subject: Re: The problem isn't C's integer philosophy; it's your design. (was: size_type doubts / integer library..)
Newsgroups: gmane.comp.lib.boost.user
Date: 2008-08-19 06:59:25 GMT
On Mon, Aug 18, 2008 at 07:05:10PM -0400, Daryle Walker wrote: > > implementing. This is one of those times. > Thanks for your deep analysis and your time. Unfortunately, it's based on the assumption that the task ID is opaque, which it is not.. Re-reading my original post, this could be blamed on me.. > > >Integer types in C and C++ are a mess. For example, I have made a > >library > >where a task is identified by a unique unsigned integer. The extra > >information > >about the tasks is stored in a std::vector. When a new task is > [snip, rearrange] > > You tasks IDs are conceptually opaque, why is any external code > wanting to mess with them? The external code shouldn't be doing > There are TWO task IDs: one is used by the library (which I also made), and that one _is_ opaque (at least to library clients), it _is_ typedef, and it is not even an integer (it's a pointer). Now, to every created task, I need to assign a positive[*] index (in an application which just uses the library) which is _not_ opaque: the indices are vertex IDs which are in turn used to construct a CSR representation (edge-lists) of a certain graph which is in turn operated on by an external library. (You may remember my earlier post where I proposed that the CSR class from Boost.Graph provides a documented, public way of accessing the raw CSR vectors.) I will call these "other" IDs "task(Continue reading)
RSS Feed