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
I'm working through an stepwise explanation of :code_do*range behavior in a blog post, and am wondering something:
The way it's defined in Clojush it will (1) pop a :code item, and (2) execute that code item at least twice, at the end of the loop, when the counters are equal.
Is that actually the desired effect? I ask only because the continuation form produced when the looping is finished is equivalent to (:q1 (:k1 :k2 :q1)), where :q1 is the code item and the two numbers are the (identical) start and end counters. So the counters are preserved, and pushed to the :integer stack. The :code item is executed twice: once as to-do and once as popped-arguments at the end.
It seems as though a :code_quote is missing from the second instance in the continuation form. Or not! I don't know what's intended, because there's no real documentation on the instruction itself.
It just seems like there's an extra.
The text was updated successfully, but these errors were encountered:
I'm working through an stepwise explanation of
:code_do*range
behavior in a blog post, and am wondering something:The way it's defined in Clojush it will (1) pop a
:code
item, and (2) execute that code item at least twice, at the end of the loop, when the counters are equal.Is that actually the desired effect? I ask only because the continuation form produced when the looping is finished is equivalent to
(:q1 (:k1 :k2 :q1))
, where:q1
is the code item and the two numbers are the (identical) start and end counters. So the counters are preserved, and pushed to the:integer
stack. The:code
item is executed twice: once asto-do
and once aspopped-arguments
at the end.It seems as though a
:code_quote
is missing from the second instance in the continuation form. Or not! I don't know what's intended, because there's no real documentation on the instruction itself.It just seems like there's an extra.
The text was updated successfully, but these errors were encountered: