Re: Stream manipulator question

From: Jonathan Turkanis (
Date: 03/24/04

Date: Tue, 23 Mar 2004 16:06:16 -0700

"Kevin Goodsell" <> wrote in
message news:3h38c.53963$
> Christopher Benson-Manica wrote:

> Well, the ones I've tried have failed. The whole thing (deriving
from a
> stream class) confuses me a little - I'm not sure which functions
> virtual and which aren't. Someone said flush is not, but I don't
> how it could work otherwise. It looks like it just calls a function
> the stream buffer class, which I guess is probably virtual (I know
> must be a virtual call in there somewhere).

flush calls basic_streambuf::pubsync() (non-virtual) which calls
basic_streambuf::sync() (virtual).