Created
January 3, 2018 00:01
-
-
Save joboccara/a6d3038d3c8c779262dc549555b7668e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string> | |
#include <boost/spirit/include/karma.hpp> | |
int main() | |
{ | |
using boost::spirit::karma::int_; | |
using boost::spirit::karma::generate; | |
std::string result; | |
generate( | |
std::back_inserter(result), // the output | |
int_, // the generator | |
42 // the input | |
); | |
std::cout << result << "\n\n"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment