Boost logo

Boost :

From: Beman Dawes (bdawes_at_[hidden])
Date: 2002-09-01 19:03:22


At 09:43 AM 8/31/2002, Stephen Nutt wrote:

>Thank you, I'll go ahead and make those changes. Quick question though.
>The current specializations are
> // specializatons: 1=long, 2=int, 3=short, 4=signed char,
> // 6=unsigned long, 7=unsigned int, 8=unsigned short, 9=unsigned
long
> // no specializations for 0 and 5: requests for a type > long are in
>error
>
>It would seem 'cleaner' to shift everything along to make the new ones
> // specializatons: 1=int64_t, 2=long, 3=int, 4=short, 5=signed char,
> // 7= uint64_t, 8=unsigned long, 9=unsigned int, 10=unsigned short,
>11=unsigned long
> // no specializations for 0 and 6: requests for a type > int64_t are
in
>error

Yes, agreed.

>However I worry if this might break existing code. Is the template
>int_least_helper supposed to be used outside of integer.hpp, or is it
>purely
>an internal implementation for the templates?

They are just internal implementation details.

> If it is supposed to be
>internal I wonder if I should move it into a nested namespace for the
>following reasons.
>1) Make the fact that int_least_helper should not be used outside of
>integer.hpp explicit
>2) Cause compile errors for anyone currently using int_least_helper
forcing
>them to preferably not use int_least_helper, or at least recognise the
new
>values.

Yes, agreed. If the code were written today, they would certainly be placed
in namespace detail or similar.

--Beman


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