Syntax for Single Parse Collection Transformations #10
Replies: 3 comments 2 replies
-
|
If |
Beta Was this translation helpful? Give feedback.
-
Proposal 1IssuesFor the folder operation which requires a default accumulator/state, it needs to be parsed dynamically (as a not static value), hence there will be confusion as to whether the fold is being executed and the result parsed to the group, or if the group is triggering that statement. By pure syntax and grammar, the behaviour is unknown. Hence extra syntax will need to be implemented for collection transformations. |
Beta Was this translation helpful? Give feedback.
-
|
A method Python Inspired List Comprehension. Example 1Example 2Example 3Example 4Example 5NotesI do not think the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
For discussion of possible ideas for the optimal syntax to make single parse collection transformers clear to understand in both data manipulation behaviour and execution behaviour (being feed-forward, cache-less). #6 #7 #8 #9
Example of Cache-Full Collection Transformer
A cache-full transformer is ones more akin to methods used in most languages, where each stage of transformation yields all results, before continuing to the next stage.
Example of Cache-Less Collection Transformer
The language would iterate through the array, any values which parse the filter, are then passed on to the fold.
This whole expression produces a single value output, with no temporary container intermediaries.
Beta Was this translation helpful? Give feedback.
All reactions