Boost logo

Boost :

From: Moore, Paul (paul.moore_at_[hidden])
Date: 2001-01-12 09:34:12


From: Paul A. Bristow [mailto:pbristow_at_[hidden]]
>
> I strongly support the need for bounded containers,
>
> and also that an exception should result from trying to overfill.
>
> From the speed increase afforded by the boundedness,
> we can surely afford the cost of checking for reliablity of
> the latter.

I agree with this. And I also strongly dislike the name "cdeque" in this
context. The "c" implied "circular" to me, which implied a completely
different structure - something I have previously seen called a "ring". This
is a fixed length queue which drops elements off the bottom when it gets
overfilled. Useful for things like MRU lists and the like. While I would
like to see such a data structure, and it clearly has a number of
similarities with what people are talking about here (the implementation is
almost identical), it obviously is NOT what people are actually proposing.

I'd suggest avoiding over-abbreviation, and having

    bounded_xxx (fixed size, exception on overflow)
    circular_xxx (fixed, size, MRU semantics)

Paul.


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