Move around some namespaces for documentation purposes.

Fix problems with building on clang 2.8.
Remove unneeded function for get_engine() and fix functor<> calls that take a Boxed_Value
This commit is contained in:
Jason Turner
2011-03-15 17:35:14 -06:00
parent 9dd9ffec46
commit 637164e457
9 changed files with 1478 additions and 1437 deletions

View File

@@ -49,29 +49,6 @@ namespace chaiscript
};
}
namespace detail
{
template<typename Ret>
struct Do_Call
{
template<typename Fun>
static Boxed_Value go(const boost::function<Fun> &fun, const std::vector<Boxed_Value> &params)
{
return Handle_Return<Ret>::handle(call_func(fun, params));
}
};
template<>
struct Do_Call<void>
{
template<typename Fun>
static Boxed_Value go(const boost::function<Fun> &fun, const std::vector<Boxed_Value> &params)
{
call_func(fun, params);
return Handle_Return<void>::handle();
}
};
}
}
#define BOOST_PP_ITERATION_LIMITS ( 0, 10 )
@@ -143,3 +120,35 @@ namespace chaiscript
#undef n
#endif
#ifndef BOOST_PP_IS_ITERATING
namespace chaiscript
{
namespace detail
{
template<typename Ret>
struct Do_Call
{
template<typename Fun>
static Boxed_Value go(const boost::function<Fun> &fun, const std::vector<Boxed_Value> &params)
{
return Handle_Return<Ret>::handle(chaiscript::detail::call_func(fun, params));
}
};
template<>
struct Do_Call<void>
{
template<typename Fun>
static Boxed_Value go(const boost::function<Fun> &fun, const std::vector<Boxed_Value> &params)
{
chaiscript::detail::call_func(fun, params);
return Handle_Return<void>::handle();
}
};
}
}
#endif