aboutsummaryrefslogtreecommitdiff
path: root/system/include
diff options
context:
space:
mode:
authorChad Austin <chad@imvu.com>2013-02-25 16:04:14 -0800
committerJukka Jylänki <jujjyl@gmail.com>2013-04-12 14:24:06 +0300
commit04d596f0408ccd7b591cf323bf2602b545155dcc (patch)
tree75e81aef8707c8d4ed8082625047ca55cf407d5c /system/include
parent68845c447da1f53441e0399279c6cb99535d3076 (diff)
Replace operator call with a method invoking said operator call, so isinstance works again. When Function.create exists we can have the benefit of both worlds.
Diffstat (limited to 'system/include')
-rwxr-xr-xsystem/include/emscripten/bind.h18
1 files changed, 2 insertions, 16 deletions
diff --git a/system/include/emscripten/bind.h b/system/include/emscripten/bind.h
index 1ef462bc..5806d57f 100755
--- a/system/include/emscripten/bind.h
+++ b/system/include/emscripten/bind.h
@@ -141,12 +141,6 @@ namespace emscripten {
GenericFunction invoker,
GenericFunction method);
- void _embind_register_class_operator_call(
- TYPEID classType,
- unsigned argCount,
- TYPEID argTypes[],
- GenericFunction invoker);
-
void _embind_register_class_operator_array_get(
TYPEID classType,
TYPEID elementType,
@@ -754,16 +748,8 @@ namespace emscripten {
}
template<typename ReturnType, typename... Args, typename... Policies>
- class_& calloperator(Policies...) {
- using namespace internal;
-
- typename WithPolicies<Policies...>::template ArgTypeList<ReturnType, Args...> args;
- _embind_register_class_operator_call(
- TypeID<ClassType>::get(),
- args.count,
- args.types,
- reinterpret_cast<internal::GenericFunction>(&internal::FunctorInvoker<ClassType, ReturnType, Args...>::invoke));
- return *this;
+ class_& calloperator(const char* methodName, Policies... policies) {
+ return method(methodName, &ClassType::operator(), policies...);
}
template<typename ElementType, typename IndexType>