Fixed a problem with the "quoted" valexpr function

This commit is contained in:
John Wiegley 2010-03-05 22:13:11 -05:00
parent fe95280492
commit b90ce78906

View file

@ -470,11 +470,11 @@ value_t report_t::fn_justify(call_scope_t& scope)
value_t report_t::fn_quoted(call_scope_t& scope) value_t report_t::fn_quoted(call_scope_t& scope)
{ {
interactive_t args(scope, "s"); interactive_t args(scope, "v");
std::ostringstream out; std::ostringstream out;
out << '"'; out << '"';
foreach (const char ch, args.get<string>(0)) { foreach (const char ch, args.value_at(0).to_string()) {
if (ch == '"') if (ch == '"')
out << "\\\""; out << "\\\"";
else else