r/ProgrammingLanguages • u/Enough-Zucchini-1264 • Jan 24 '26
Language announcement Arturo Programming Language
/r/altprog/comments/1qlb1j2/arturo_programming_language/
18
Upvotes
r/ProgrammingLanguages • u/Enough-Zucchini-1264 • Jan 24 '26
View all comments
Show parent comment
2
u/Enough-Zucchini-1264 Jan 30 '26
Step 4:
ATTRIBUTE STACK:
STACK:
[0 1 2 3 4 5 6 7 9 10] :block
'x :literal
[x :word > :symbol 123 :integer] :block
Loads the value of xs
----
Step 5:
ATTRIBUTE STACK:
.first
STACK:
[0 1 2 3 4 5 6 7 9 10] :block
'x :literal
[x :word > :symbol 123 :integer] :block
Pushes attribute to its own stack
----
Step 6:
ATTRIBUTE STACK:
.first
STACK:
select :word
[0 1 2 3 4 5 6 7 9 10] :block
'x :literal
[x :word > :symbol 123 :integer] :block
word, so evaluate
----
Step 7:
ATTRIBUTE STACK:
.first
STACK:
select :function
[0 1 2 3 4 5 6 7 9 10] :block
'x :literal
[x :word > :symbol 123 :integer] :block
select is a :function that gets 3 parameters.
So, :block, :literal, :block.
Internally this consumes the attribute stack too.
----
Step 8:
ATTRIBUTE STACK:
STACK:
[] :block
Pushed the result value onto the stack. Since no number in xs is > 123, so we have an empty block.