aboutsummaryrefslogtreecommitdiff
path: root/system
diff options
context:
space:
mode:
authorChad Austin <caustin@gmail.com>2014-03-22 23:52:57 -0700
committerChad Austin <chad@chadaustin.me>2014-03-28 23:56:40 -0700
commit6291f97039f94eb2eaeae7535a7dbe9c6ff8bbe5 (patch)
tree2c6eb2deb474a78bff5410953e19eb96d07f141e /system
parent464f4a3cace3eba27c145d347d031930b9630a51 (diff)
make val::new_ compatible with asm.js
Diffstat (limited to 'system')
-rw-r--r--system/include/emscripten/val.h12
1 files changed, 3 insertions, 9 deletions
diff --git a/system/include/emscripten/val.h b/system/include/emscripten/val.h
index 49b143c1..501e927d 100644
--- a/system/include/emscripten/val.h
+++ b/system/include/emscripten/val.h
@@ -28,8 +28,8 @@ namespace emscripten {
EM_VAL _emval_new(
EM_VAL value,
unsigned argCount,
- internal::TYPEID argTypes[]
- /*, ... */);
+ internal::TYPEID argTypes[],
+ ...);
EM_VAL _emval_get_global(const char* name);
EM_VAL _emval_get_module_property(const char* name);
@@ -232,14 +232,8 @@ namespace emscripten {
WithPolicies<>::ArgTypeList<Args...> argList;
// todo: this is awfully similar to operator(), can we
// merge them somehow?
- typedef EM_VAL (*TypedNew)(
- EM_VAL,
- unsigned,
- TYPEID argTypes[],
- typename BindingType<Args>::WireType...);
- TypedNew typedNew = reinterpret_cast<TypedNew>(&_emval_new);
return val(
- typedNew(
+ _emval_new(
handle,
argList.count,
argList.types,