Merge Tuple from the trunk

[SVN r67590]
This commit is contained in:
Steven Watanabe
2011-01-02 20:25:11 +00:00
parent e36faf7e25
commit a2c9608ef0
5 changed files with 230 additions and 147 deletions

View File

@ -120,6 +120,13 @@ int test_main(int argc, char * argv[] ) {
is3 >> set_close(']');
BOOST_CHECK(bool(is3 >> ti2));
// Make sure that whitespace between elements
// is skipped.
useThisIStringStream is4("(100 200 300)");
BOOST_CHECK(bool(is4 >> std::noskipws >> ti1));
BOOST_CHECK(ti1 == make_tuple(100, 200, 300));
// Note that strings are problematic:
// writing a tuple on a stream and reading it back doesn't work in
// general. If this is wanted, some kind of a parseable string class