$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Robert Kawulak (kawulak_at_[hidden])
Date: 2008-05-20 15:20:37
> From: Neal Becker
>    constrained & operator = (const value_type & v)
>     {
>         if(constraint()(v))
>             _value = v;
>         else
>             error_handler()(_value, v, _constraint());
> 
>         BOOST_ASSERT(_check_value());  << Isn't this redundant?
>         return *this;
>     }
>  
> Maybe this should be:
> 
>   constrained & operator = (const value_type & v)
>     {
>         if(constraint()(v))
>             _value = v;
>         else {
>             error_handler()(_value, v, _constraint());
> 
>             BOOST_ASSERT(_check_value());
>         }
>         return *this;
>     }
Maybe it is a bit redundant, but intentional -- after all, you don't know what
operator = does for sure. :P Anyway, it shouldn't cause any harm this way, but
can help to find some rare bugs which would break the invariant.
Best regards,
Robert