-
Notifications
You must be signed in to change notification settings - Fork 55
Description
Is implicit multiplication possible with Expression? I see according to #39 that implicit multiplication is sort of possible using a custom operator for parenthesis, but I haven't seen any indication that implicit multiplication without parenthesis is possible.
For example: try Expression("2 * pi") is valid, but try Expression("2pi") is not.
Using the recommendation in #39, I could add the custom operator for parenthesis, but in my case (a scientific calculator that takes user input), I'd have to parse the input beforehand and intelligently wrap anything that should be implicitly multiplied in parenthesis before passing it to Expression.
So is there any other way to enable implicit multiplication, or will I have to use the recommendation in #39 along with parsing the input separately to intelligently wrap certain parts of the expression in parenthesis?