Boost logo

Boost Users :

From: David Abrahams (dave_at_[hidden])
Date: 2005-12-02 19:23:47


"Nathan E. Moore" <nate_at_[hidden]> writes:

> On Thu, 01 Dec 2005 18:16:21 -0200, Bruno Martínez wrote:
>> I don't think it's psossible, because std::stack doesn't expose enough
>> information. Either use deque/vector directly or inherit from std::stack
>> to get access to the inner deque.
>>
>> Regards,
>> Bruno
>
> Inheriting from the std::stack is horrible idea. It is not portable.

?? How so?

> Not to mention that stack lacks a virtual destructor.

So use private inheritance if you're worried.

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net