aboutsummaryrefslogtreecommitdiff
path: root/tests/embind/embind_test.cpp
diff options
context:
space:
mode:
authorChad Austin <chad@imvu.com>2014-05-07 16:20:55 -0700
committerBruce Mitchener <bruce.mitchener@gmail.com>2014-05-21 22:58:16 +0700
commit1bad0e2ae1038b9ae6ba362c73ca9d3fc8f17e11 (patch)
tree40ec5c3653f6498bf95b1898ddde3a8a856f26e2 /tests/embind/embind_test.cpp
parent6e7397193370ebad6be01438ab1e65223820e909 (diff)
give a good error message when a pure virtual function is not implemented in JavaScript
Diffstat (limited to 'tests/embind/embind_test.cpp')
-rw-r--r--tests/embind/embind_test.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/embind/embind_test.cpp b/tests/embind/embind_test.cpp
index e14a633b..1bfd0ef7 100644
--- a/tests/embind/embind_test.cpp
+++ b/tests/embind/embind_test.cpp
@@ -1161,7 +1161,7 @@ EMSCRIPTEN_BINDINGS(interface_tests) {
class_<AbstractClass>("AbstractClass")
.smart_ptr<std::shared_ptr<AbstractClass>>("shared_ptr<AbstractClass>")
.allow_subclass<AbstractClassWrapper>("AbstractClassWrapper")
- .function("abstractMethod", &AbstractClass::abstractMethod)
+ .function("abstractMethod", &AbstractClass::abstractMethod, pure_virtual())
// The select_overload is necessary because, otherwise, the C++ compiler
// cannot deduce the signature of the lambda function.
.function("optionalMethod", select_overload<std::string(AbstractClass&, std::string)>(