Fix util::ostringstream, fix pretty-printing, stub out new globals

This commit is contained in:
2023-03-05 01:51:25 -05:00
parent db234c2934
commit 86a27ef2d4
13 changed files with 455 additions and 282 deletions

View File

@@ -297,7 +297,7 @@ eng::string World::probe_lua(int64_t actor_id, const eng::string &lua) {
if (msg.empty()) {
for (int i = top + 1; i <= lua_gettop(L); i++) {
LuaSpecial root(i);
pprint(LS, root, true, ostream);
pprint(LS, root, PrettyPrintOptions(), ostream);
// TODO: this endl is unnecessary if we just printed a newline.
(*ostream) << std::endl;
}
@@ -876,7 +876,7 @@ void World::run_scheduled_threads() {
LuaStack LSCO(CO);
if (LS.ckboolean(print)) {
for (int i = 1; i <= lua_gettop(CO); i++) {
pprint(LSCO, LuaSpecial(i), true, ostream);
pprint(LSCO, LuaSpecial(i), PrettyPrintOptions(), ostream);
(*ostream) << std::endl;
}
}