Wrong return type inference #3625
dvd101x
started this conversation in
Design decisions
Replies: 1 comment
-
|
Indeed, the efforts Jos and I have been making on a new core engine for mathjs (see e.g. https://code.studioinfinity.org/StudioInfinity/nanomath) explicitly include return type annotations on all mathjs functions. The primary motivation is that then implementations of the functions can be assembled that don't re-check the types on every internal call, which saves a lot of time. Since this is unlikely to be addressed short of an engine overhaul, moving to Discussions. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Some functions / methods assume that if the input is of a certain type the output will be of the same type.
Maybe the dispatch system could also include information on the type that will be returned for a certain input.
Beta Was this translation helpful? Give feedback.
All reactions