d1e702c1f745428a7bc53cbbd80b0c283ca52de1 |
|
03-Feb-2010 |
Nicolas Catania <niko@google.com> |
Added basic_ios abstraction and finished cout/cerr implementation. basic_ios was missing. we should have: ostream -> basic_ios -> ios_base basic_ios's role is very minor for us, it just holds the streambuf where the writes happen. In a real STL it does a bit more, it deals with the numerous flags that can be set on a stream. The ostream implementation is now complete since it can get the streambuf from its base class to perform the 2 ops supported: - flush() - operator<<(char*) The final piece was a concrete implementation of a streambuf to output the strings to stdout or stderr. This is done in a new class stdio_filebuf which wraps a regular stdio.h stream. For cerr we use stderr to build the stdio_filebuf instance that cerr will wrap. Same for cout and stdout.
/external/astl/tests/test_streambuf.cpp
|
743c6a2694bf16bf29d516c906363199a7bccf86 |
|
29-Jan-2010 |
Nicolas Catania <niko@google.com> |
Changed char_traits to be a template. Some libraries expect it to be so. Left the base definition empty to generate an error when something other than char is used.
/external/astl/tests/test_streambuf.cpp
|
0b70d74ee05462446d178279177702296709eb9e |
|
27-Jan-2010 |
Nicolas Catania <niko@google.com> |
Basic streambuf implementation. Needed to finish the ostream. We are not expected to use this class a lot since we are going to rely on the stdio implementation for all the work. Still needed to make the compiler happy but did not spent too much effort on it. For instance only output buffer operations are supported.
/external/astl/tests/test_streambuf.cpp
|