Ticket #2944: boost_archive_load_test.cpp
| File boost_archive_load_test.cpp, 454 bytes (added by , 14 years ago) |
|---|
| Line | |
|---|---|
| 1 | #include <iostream> |
| 2 | #include <fstream> |
| 3 | #include <string> |
| 4 | |
| 5 | #include <boost/archive/xml_iarchive.hpp> |
| 6 | |
| 7 | void test_xmlArchive(); |
| 8 | |
| 9 | int main(int argc, char *argv[]) |
| 10 | { |
| 11 | test_xmlArchive(); |
| 12 | |
| 13 | return 0; |
| 14 | } |
| 15 | |
| 16 | void test_xmlArchive() |
| 17 | { |
| 18 | std::string filename("my_archive.xml"); |
| 19 | |
| 20 | // open the archive |
| 21 | std::ifstream ifs(filename.c_str()); |
| 22 | assert(ifs.good()); |
| 23 | |
| 24 | printf("opening...\n"); |
| 25 | boost::archive::xml_iarchive ia(ifs); |
| 26 | printf("opened\n"); |
| 27 | } |
| 28 |
