
1 Jun
2011
1 Jun
'11
5:10 p.m.
Den 01-06-2011 15:49, Andrew Sutton skrev:
I think there's value in considering parameterizing over the container type. There are probably use cases where bounding the heap size is useful. I'd like to know about these use cases before committing to make the change, however.
The cases are abundant. So many problems are only tractable for small input sizes. In my PhD work I have algorithms that will need many small priority queues. But even for larger sizes, it is still useful to pass e.g. stlsoft::auto_buffer as a container. An allocator is not near as powerful. Also, take a look at the STL from Electronic Arts ... they provide this feature for several types, e.g. circular_buffer. -Thorsten