Boost logo

Boost :

From: George M. Garner Jr. (gmgarner_at_[hidden])
Date: 2005-08-19 19:24:33


> > component_impl() returns a void*. What
> > am I supposed to do, cast it? :-(
> Of course ;-) What else can you do with a void*?

I must have missed that day in OOP design class. :-) And I don't see what
that get's me even assuming that I cast it. The branch in the execution
path that I want to intercept occurs in basic_streambuf<>::_Xsgetn_s()
(Microsoft SL v8.0) or basic_streambuf<>::xgetn() (other SL). Even assuming
that I cast your void pointer I won't get a chance to do so unless I replace
_Xsgetn_s/xsgetn in the basic_streambuf<> vtable. The only (legitimate) way
to do that is by derivation. Derivation is still a respectable means of
specialization so far as I know.

> Even better, if you can show that your implementation is superior to
> the current one, I can simply use yours instead. <

Well you could do that of course. But what happens in 6 months when I want
to specialize something else? I don't see what advantage there is to making
the typedefs private rather than protected. You could provide an accessor
for pback_size_. I don't see why that shouldn't be provided in any case.

> I'll have to review the old messages to remember what the sticking points
> were.
> I seem to remember there was a problem with STLPort requiring a larger
> putback
> buffer than other libraries.

After some subsequent testing I found that I didn't need to modify that part
of the code.



Boost list run by bdawes at, gregod at, cpdaniel at, john at