$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: David Abrahams (david.abrahams_at_[hidden])
Date: 2001-12-27 16:48:08
On Thursday, December 27, 2001, at 03:55 AM, ncmcantrip wrote:
>>
>> Interesting.
>>
>> Did you consider asserting or throwing on b < e precondition
>> violations?
>
> As a precondition, it is a logical error to insert into the set elements
> that are already present. The type std::set<> doesn't throw if you try
> to insert the same element again. Passing a range to std::set<> with
> the
> iterators reversed does not result in an exception.
>
> I cannot imagine how client code could respond meaningfully to such an
> exception.
>
What about asserting, as Beman suggested?
-Dave