-
Notifications
You must be signed in to change notification settings - Fork 29
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
basic loops things needed #453
Comments
Okay before diving in more I wanted to spec this out with a gear and I have something a little like this but I really dont like it
also requires if statements which we can do, and anyways the pipes get super weird and I bet @adamchalmers had better ideas here but this is a good example to make work, as in the gear not my syntax |
@jessfraz check out this issue in the KCL experimentation repo that @adamchalmers set up: KittyCAD/kcl-experiments#6 |
okay yeah I like @Irev-Dev example it seems like patterns, unless I'm hallucinating what patterns are but also like @adamchalmers as well |
i like the loop in the pipe like @Irev-Dev has and patterns like that I guess my question is do we need a regular loop then? just like a |
this is my mental notes so i can mess around later
[0..10]
in the parser should expand to[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
#456for text in v { innershit }
needs to parsefor num in [0..10] { innershit }
should parse the same wayobj.thing
whereobj = {thing: 2}
#454array[0]
wherearray = [0, 1, 2]
#455ForLoopExpression
type and add it to the ast like:something like that
added some failing tests here: f3589e0
The text was updated successfully, but these errors were encountered: