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
Currently thinking about adding a feature similar to pipes or fluent syntax such that a pipeline of function transformations can be built from left to right. For me, this is easier to read than nested function application.
This issue can serve to document my thoughts through the design of this.
Ideally, this gets added to the grammar as another simple recursive operator like
expression : expression PIPEOPERATOR expression
This would require type checks at runtime, which is fine. The only issue is how to handle piping into a function that takes more than one argument. For example, I'd like to be able to do something like:
# filter function has 2 parameters, list and function.
list | filter(\ item { item == 1 })
However, as it stands, the function application would throw an exception for not having the required number of arguments.
Currently thinking about adding a feature similar to pipes or fluent syntax such that a pipeline of function transformations can be built from left to right. For me, this is easier to read than nested function application.
For this to be most useful, I'd have to change the order of some of the built in function signatures.
The text was updated successfully, but these errors were encountered: