C++11 cleanups

This commit is contained in:
Jason Turner
2011-09-26 07:14:24 -06:00
parent db0e342a96
commit 488f2ea393
3 changed files with 16 additions and 24 deletions

View File

@@ -348,17 +348,13 @@ namespace chaiscript
static std::vector<Boxed_Value> do_return_boxed_value_vector(FunctionType f,
const dispatch::Proxy_Function_Base *b)
{
typedef decltype(std::mem_fn(f)) MemFunType;
typedef typename MemFunType::result_type Vector;
Vector v = (b->*f)();
auto v = (b->*f)();
std::vector<Boxed_Value> vbv;
for (typename Vector::const_iterator itr = v.begin();
itr != v.end();
++itr)
for (const auto &o: v)
{
vbv.push_back(const_var(*itr));
vbv.push_back(const_var(o));
}
return vbv;