stela/interpreter.cpp

16 lines
405 B
C++

#include "interpreter.hpp"
#include "command.hpp"
#include <sstream>
using namespace stela;
std::string Interpreter::to_string() const
{
std::stringstream s;
s << "Interpreter: " << this->commands.size() << " commands received from command line.\n";
for(size_t i = 0; i < this->commands.size(); i++) {
s << " * " << this->commands[i].to_string() << '\n';
}
return s.str();
}