You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Issue
When using optional arguments with embind, it would be more intuitive and convenient to allow omitting the optional arguments entirely, rather than requiring passing undefined for the optional parameters.
This replaces `_0: Foo | undefined` with `_0?: Foo` for any optional
arguments at the end of function, which allows for more idiomatic TS.
Fixesemscripten-core#21776
…1786)
This replaces `_0: Foo | undefined` with `_0?: Foo` for any optional
arguments at the end of function, which allows for more idiomatic TS.
Fixes#21776
Please include the following in your bug report:
Version of emscripten/emsdk:
Issue
When using optional arguments with embind, it would be more intuitive and convenient to allow omitting the optional arguments entirely, rather than requiring passing undefined for the optional parameters.
I would expect the generated JavaScript bindings to allow calling the function like this:
Instead of requiring the following:
I noticed a comment on the original optional implementation pull request (#21076) mentioning plans to support this feature.
The text was updated successfully, but these errors were encountered: