crafted a macro for doing "(let loop ((arg1 val1) ...) body ...)" wondering if any alternatives there is already existing #1559
Inc0n
started this conversation in
Show and tell
Replies: 2 comments 4 replies
-
May be somewhat similar to "named let" from Scheme [1] [2] or FWIW, [1] Search for "Named let" here. |
Beta Was this translation helpful? Give feedback.
1 reply
-
It’s hard to think of possible existing alternatives without seeing some uses — can you give an example of where you’d use this over a loop? I’m thinking this could be a useful way to define a |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Picking up janet again for doing a side project, missing the "let loop" recursion when needed doing some simple recursion in a functional manner, it looks like a powerful
loop
macro exist but for other purposes. So why not write my own.it worked for my simple case, choosing the name of
label
partly due to commonlisplabels
but alsolet
andloop
are already taken right? I want to know if any existing solution is out there already that I have missed. If not would it be a good addition to janet possibly?Beta Was this translation helpful? Give feedback.
All reactions