Boost logo

Boost :

From: David Abrahams (abrahams_at_[hidden])
Date: 2000-06-06 18:32:54

From: "Moore, Paul" <paul.moore_at_[hidden]>
> > operator>>() is just the wrong way to stream objects which
> > don't have a default constructor - those types should be
> > constructible from a stream parameter. Maybe we need an
> > istream_traits<T> class which describes the way
> > to produce a T from an istream?
> That may well not be a bad idea in itself, but let's try to avoid getting
> bogged down in redesign again.

I agree with that.

> I propose
> 1. Accept the exception-throwing version as is.
> 2. Review the need for a no-throw version, and add it later if needed.
> 3. Consider istream_traits as a separate issue. If it's implemented,
> stream_cast with a view to changing the implementation (but not the
> interface) to use it. Until then, just accept the limitation on default
> constructible types only.

I would like this, but if I'm not mistaken (am I?) the original implementor
has some affection for the non-throwing version. We really ought to give his
concerns due consideration.


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