This is the mail archive of the mailing list for the libstdc++ project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Specializations of std::char_traits

On Friday, July 18, 2003, at 4:18AM, Gabriel Dos Reis wrote:

Matt Austern <> writes:

|   2. I deliberately avoided standard algorithms like std::copy and
| std::fill_n.  Rationale: at present, bits/char_traits.h is almost
| self-contained.  It depends on <cstring> and bits/fpos.h and nothing
| else.  I don't want to introduce a new dependence unless there's a
| very strong reason for it.

The only way to get std::char_traits<> is by including <string>, which
already has much  more dependencies.

If that's true, then I take back my concern about dependencies. And
it looks like it is true. I was mistakenly assuming that char_traits was
defined as a complete type in <iosfwd>, but I see that it's not. It looks
like we only need it as a complete type in <ios> (which includes
<string>) and in <string> itself.

So yes, I'll make that change and I'll stop going to heroic lengths to
avoid dependency on all of the stuff that <string> already depends on.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]