From c3535d06c89732a0ba4c13274702b0f48198ae79 Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Sun, 8 Nov 2009 23:40:42 -0500 Subject: Redesigned the expr_t, predicate_t, query_t classes --- src/format.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/format.cc') diff --git a/src/format.cc b/src/format.cc index 8ac14aa2..f3f52f20 100644 --- a/src/format.cc +++ b/src/format.cc @@ -72,8 +72,7 @@ namespace { string temp(p); ptristream str(const_cast(p)); expr_t expr; - expr.parse(str, single_expr ? expr_t::PARSE_SINGLE : expr_t::PARSE_PARTIAL, - &temp); + expr.parse(str, single_expr ? PARSE_SINGLE : PARSE_PARTIAL, temp); if (str.eof()) { expr.set_text(p); p += std::strlen(p); @@ -349,7 +348,7 @@ void format_t::format(std::ostream& out_str, scope_t& scope) } catch (const calc_error&) { add_error_context(_("While calculating format expression:")); - add_error_context(expr_context(elem->expr)); + add_error_context(elem->expr.context_to_str()); throw; } break; -- cgit v1.2.3