Talk:Sidex

From Esolang
Jump to navigation Jump to search

Language explanation

Can you explain to me how the language works? I see you using the code a -> + 2 2 -> b -> value.concat. I understand this as waiting until the latch a opens, then sending the value in a and + 2 2 to value.concat, and then unlocking b and sending it the result. But then surely b should be the last thing in the instruction? Also, you're saying that the if library stops threads, but it also calls them? Plokmijnuhby (talk) 20:42, 25 July 2019 (UTC)

I tried to make it use the Reverse-polish notation as well as making use the Polish notation. That is why value.concat is not in the middle of the line of code (for a clear understanding, mentally replace a as the existing a assignment, b as-is, and value.concat as another symbol, say +; now that the notation is shown (a b +), your suggested description is simply a notation-convertion to infix (a + b).) --A (talk) 23:15, 25 July 2019 (UTC)
I removed the part about stopping threads to avoid confusion, as latches already supports stopping threads. --A (talk) 23:19, 25 July 2019 (UTC)

Is there an implementation for this language? I'd like to experiment with it. Areallycoolusername (talk) 15:17, 28 July 2019 (UTC)

“Concatenative”

“Sidex is a concatenative langauge (Supporting postfix, prefix, and infix)” ← I think a conventional sense of that term is for a majority of the language’s syntax to be concatenative, and not for an arithmetic expression sublanguage only, as is the case there at the time. You’d better rephrase that as “a language with prefix arithmetic expressions” or something, otherwise it’s confusing. —arseniiv (talk) 15:59, 28 July 2019 (UTC)

If you remove all the right arrows in the syntax (which is extremely confusing), then it will look very similar to a postfix concatenative language. Say, remove all the arrows in the Jack and Jill example:
"Jack and Jill went up a hill\n" a
a "to fetch a pail of water;\n" b value.concat
b "Jack fell down, and broke his crown,\n" c value.concat
c "and Jill came tumbling after.\n" d value.concat
d std.out

--A (talk) 02:32, 29 July 2019 (UTC)