-
-
Notifications
You must be signed in to change notification settings - Fork 504
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add math-parser library #2033
Add math-parser library #2033
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good; I'm sorry that it has taken so long to merge anything related to this.
"invsec" => Some(Value::Number(Number::Complex(complex.recip().acos()))), | ||
"invcot" => Some(Value::Number(Number::Complex((Complex::new(PI / 2.0, 0.0) - complex).atan()))), | ||
|
||
_ => None, // Handle unknown function names |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A warning here (just to the console) might be useful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
when a function lookup fails we should check if an ident with that name exists, for now i changed it to be a hashmap lookup instad.
It looks like I don't have permission to push to your branch. Can you delete the test at the very bottom of |
!build |
|
From my tests, this seems to work well when replacing meval! Thank you. And sorry it took so long to get to. |
no problem, this still needs quite a bit of work to work as its own node, mainly becuase it needs some sort of compile time node generation |
That'll be a good step for the next PR. I'm looking forward to that! This one is good to merge now. |
Partly closes #2026
For more info check out the refenced issue.