aboutsummaryrefslogtreecommitdiff
path: root/tests/embind/embind_test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/embind/embind_test.cpp')
-rw-r--r--tests/embind/embind_test.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/embind/embind_test.cpp b/tests/embind/embind_test.cpp
index 0ae1801a..4d1b376b 100644
--- a/tests/embind/embind_test.cpp
+++ b/tests/embind/embind_test.cpp
@@ -1352,6 +1352,16 @@ int overloaded_function(int i, int j)
return 2;
}
+EMSCRIPTEN_BINDINGS(constants) {
+ constant("INT_CONSTANT", 10);
+ constant("STRING_CONSTANT", std::string("some string"));
+ TupleVector tv;
+ tv.x = 1;
+ tv.y = 2;
+ tv.z = 3;
+ constant("VALUE_TUPLE_CONSTANT", tv);
+}
+
EMSCRIPTEN_BINDINGS(tests) {
register_js_interface();