Boost logo

Boost :

From: Jeffrey C. Jacobs (darklord_at_[hidden])
Date: 2002-09-13 12:12:37


"David Abrahams" <dave_at_[hidden]> wrote in message
news:09af01c25aaf$a3e92f20$6401a8c0_at_boostconsulting.com...
> From: "Jeffrey C. Jacobs" <darklord_at_[hidden]>
>
> > BTW David, you DO realize you name is mentioned elsewhere in my comments
> > about integrating this library with your integer_traits library? Any
> > thoughts on that?
>
> No, I didn't realize that. I haven't had any time to look at this. If you
> can get Daryle Walker's agreement on some patches, I think I'll be
inclined
> to agree too. Daryle has become the main architect of the integer stuff at
> Boost.

Oh! Oops, well I guess the reason I suggest integration is the same reason
I made a mistake! integer_traits, numeric_traits, sign_traits: so much to
keep track of. On the other hand, 1-header, 1-function is a very reasonable
pardigm. IMHO though sign_traits is SUCH a simplistic class it probably
should not be its own class. And when I wrote the comment, I think I was
confusing boost::detail::numeric_traits with boost::integer_traits. I did
put sign_traits in the "detail" namespace (implying in the detail
subdirectory) which is why I was probably thinking of you and numeric_traits
and given what numeric_traits does, it may be more appropriate for
numeric_traits than integer_traits which only acts to make min and max a
constant static expression and has little to do with sign. So given all
that, what do others think:

Is it better to leave sign_traits a stand alone header, or

Integrate it into an existing library's functionality -- after all isn't the
goal to UNIFY the integer traits, not create all these mini-facets? And if
this be the case, would numeric_traits or integer_traits be better?

If the former, I still have some unanswered questions to clean up, including
a problem where a Template Function that uses a Template Class's typedef
requires the typedef to be specified even if the unspecialized form of the
function is never actually used! :(

Jeffrey.

http://groups.yahoo.com/group/boost/files/TimeHorse/sign_traits.hpp


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk