
----- Original Message ----- From: "Robert Bell" <belvis@imageworks.com> To: <boost@lists.boost.org> Sent: Sunday, May 16, 2004 6:53 PM Subject: [boost] Re: Ranged type mini-library submission
christopher diggins wrote:
[ ... ]
template < class constraints_policy, class error_policy = default_error_policy, bool implicit_conversion_policy = true >
[...]
I just noticed that the implicit_conversion_policy policy argument controls whether a raw value can be assigned to a constrained_value, but has nothing to say about whether a constrained_value can be constructed from a raw value or whether a constrained value can be converted to a raw value.
Bob
This was intentional. I am of the point of view that implicit widening conversions are not something that needs to be switched on/off. The reason I included the policy was so that I could implement constrained values that would not have implicit narrowing conversions which is a source of many errors in C++ code. Christopher Diggins http://www.cdiggins.com http://www.heron-language.com