summaryrefslogtreecommitdiff
path: root/unotest
diff options
context:
space:
mode:
authorStephan Bergmann <stephan.bergmann@allotropia.de>2024-05-08 11:08:15 +0200
committerStephan Bergmann <stephan.bergmann@allotropia.de>2024-05-09 18:48:29 +0200
commitc6f39e2deedd93ccf52ca5bb4402cabc3e8bdda7 (patch)
tree17852bf618515435197888cdcaa9fbc998461fb6 /unotest
parent227078bc8d1e37d80eab2d50478ec5fc6345a616 (diff)
Embind: Fix uno_Any.get for null interface values
...which had caused an additional getNull/isNull check for a469aea9c0b532d928cd41e389c9c51de1af06f0 "Emscripten: Towards a working C++ UNO bridge" to fail Change-Id: Ibe87ca05f795253c9ede8cab6f96da8fe4496f87 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167344 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Diffstat (limited to 'unotest')
-rw-r--r--unotest/source/embindtest/embindtest.js17
1 files changed, 17 insertions, 0 deletions
diff --git a/unotest/source/embindtest/embindtest.js b/unotest/source/embindtest/embindtest.js
index 3944f399e3b1..00d9ac68cd3c 100644
--- a/unotest/source/embindtest/embindtest.js
+++ b/unotest/source/embindtest/embindtest.js
@@ -1027,6 +1027,23 @@ Module.addOnPostRun(function() {
outparamindex.delete();
outparam.delete();
}
+ {
+ const params1 = new Module.uno_Sequence_any(0, Module.uno_Sequence.FromSize);
+ const outparamindex = new Module.uno_InOutParam_sequence_short;
+ const outparam = new Module.uno_InOutParam_sequence_any;
+ const ret1 = invoke.invoke('getNull', params1, outparamindex, outparam);
+ console.log(ret1.get());
+ const params2 = new Module.uno_Sequence_any([ret1]);
+ const ret2 = invoke.invoke('isNull', params2, outparamindex, outparam);
+ console.log(ret2.get());
+ console.assert(ret2.get());
+ ret1.delete();
+ params1.delete();
+ ret2.delete();
+ params2.delete();
+ outparamindex.delete();
+ outparam.delete();
+ }
});
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */