forked from amazingfate/loongoffice
...as there can be situations (cf. the newly added test code in embindtest.js) where objects that need to be deleted are passed as payload of the exception value to be thrown. So there now is a (mandatory, as Embind doesn't allow to implicitly pass undefined) third parameter now that must be an array of objects on which to call .delete(). (75fe059974dcb80c3f78110c73ab799afc6f4ca3 "Embind: throwUnoException from JS" had deliberately made throwUnoException take two arguments, because if it "directly took a css::uno::Any argument, JS client code would need to create one with `new Module.uno_Any(...)` and call .delete() on it, but there is no place where it could call .delete()". There now would be such a place, but it would probably still be tedious most of the time to explicitly construct a new uno_Any to pass into throwUnoException both as the exception and in the toDelete array. So keep that design decision to have throwUnoException take individual type and value arguments.) Change-Id: Idec029d9e500457b02d20d899b9a2328cd7a5d7e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171024 Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de> Tested-by: Jenkins