#include #include #include #include #include #include "parser.hpp" #include "dbc.hpp" #include #include #include using std::string, nlohmann::json, std::shared_ptr, std::make_shared; string load_file(const string& md_file) { std::ifstream in_file{md_file, std::ios::binary}; dbc::check(bool(in_file), fmt::format("failed to load {}", md_file)); return string(std::istreambuf_iterator(in_file), std::istreambuf_iterator()); } std::shared_ptr parse_slides(const std::string& md_file) { auto contents = load_file(md_file); Parser rp; rp.parse(contents); return rp.results(); } Parser::Parser() { deck = make_shared(); } void Parser::finalize() { } #include "./md_parser.cpp"