Moved fn_false to be a non-member function

This commit is contained in:
John Wiegley 2009-03-03 13:53:12 -04:00
parent 478998b4e9
commit 79acfc1647
2 changed files with 4 additions and 4 deletions

View file

@ -305,6 +305,9 @@ value_t report_t::fn_ansify_if(call_scope_t& scope)
}
namespace {
value_t fn_false(call_scope_t&) {
return false;
}
value_t fn_null(call_scope_t&) {
return NULL_VALUE;
}
@ -773,7 +776,7 @@ expr_t::ptr_op_t report_t::lookup(const string& name)
}
}
else if (is_eq(p, "post"))
return MAKE_FUNCTOR(report_t::fn_false);
return WRAP_FUNCTOR(fn_false);
break;
case 'q':

View file

@ -147,9 +147,6 @@ public:
value_t fn_join(call_scope_t& scope);
value_t fn_format_date(call_scope_t& scope);
value_t fn_ansify_if(call_scope_t& scope);
value_t fn_false(call_scope_t&) {
return false;
}
value_t fn_options(call_scope_t&) {
return value_t(static_cast<scope_t *>(this));