> According to sgi.com, the STL has complexity guarantees in the  
> specification
> <http://www.sgi.com/tech/stl/complexity.html>
>
> So I think we should use these.

Yup... but in general complexity is guaranteed by the /concept/ not  
the class. For example the Container concept requires C.size() to be  
in O(n) where n is the number of elements in C. There's a not at the  
bottom that says this is satisfied by vector and deque who have C.size 
() in O(1). Of course,  O(1) is in O(n) so its okay.

I think in general, giving bounds on algorithms and data structure  
operations is a "Good Thing" and we should definitely continue to do  
so (at least where relevant). Documenting the complexity of the  
iterator_category() function is probably overkill. Actually, not  
doing so would not be best practice.

Andrew Sutton
[EMAIL PROTECTED]

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Boost-docs mailing list
[email protected]
Unsubscribe and other administrative requests: 
https://lists.sourceforge.net/lists/listinfo/boost-docs

Reply via email to