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
x y : z is parsed as Optional[Times[x, y], z], according to the Wolfram Language -> Show FullForm menu item. This is also reflected in how the incremental selection works ("expand selection").
The correct parsing is Times[x, Pattern[y, z]]. There are two problems here: (1) precedence of : vs implicit multiplication (2) confusion between Optional and Pattern.
Let us look at another example:
x y_ : z (notice the _) is parsed as Optional[Times[x, Pattern[y]], z].
The correct parsing is Times[x, Optional[Pattern[y, Blank[]], z]]. Again, two issues: (1) precedence of : vs implicit multiplication (2) Pattern[y] vs Pattern[y, Blank[]]
As far as I can tell, in both cases it is only (1) that affects the functionality of the plugin, and (2) can be ignored. It affects incremental selections.
The text was updated successfully, but these errors were encountered:
Describe the bug
x y : z
is parsed asOptional[Times[x, y], z]
, according to the Wolfram Language -> Show FullForm menu item. This is also reflected in how the incremental selection works ("expand selection").The correct parsing is
Times[x, Pattern[y, z]]
. There are two problems here: (1) precedence of:
vs implicit multiplication (2) confusion between Optional and Pattern.Let us look at another example:
x y_ : z
(notice the_
) is parsed asOptional[Times[x, Pattern[y]], z]
.The correct parsing is
Times[x, Optional[Pattern[y, Blank[]], z]]
. Again, two issues: (1) precedence of:
vs implicit multiplication (2)Pattern[y]
vsPattern[y, Blank[]]
As far as I can tell, in both cases it is only (1) that affects the functionality of the plugin, and (2) can be ignored. It affects incremental selections.
The text was updated successfully, but these errors were encountered: