Better HN
topnewbestaskshowjobs
Log inSign up

Throwaway_5438

5 karma · joined Aug 6, 2019 (7y ago) · 4 submissions

Submissions

comment 7y ago · link · parent

Oh, I didn't read closely enough.

comment 7y ago · link · parent

>Fully homoiconic, all code can be accessed as data via quotations.

( https://min-lang.org/ )

>quotation >A list of elements, which may also contain symbols. Quotations can be be used to create heterogenous lists of elements of any data type, and also to create a block of code that will be evaluated later on (quoted program). Example: (1 2 3 + *)

( https://min-lang.org/learn-data-types/ )

Apparently Min functions are lists of the symbols they consist of, and can therefore be manipulated.

comment 7y ago · link · parent

You can trivially change Scheme to RPL by simply putting the function name last, instead of first. Apart from that is would be the same. There doesn't have to be a stack either.

If you mean concatenative languages (like Nim), then the difference is that a function in concatenative languages can push and pull an arbitrary number of arguments. This makes it trivial for a function to return two arguments, of which the next to functions use one each. It makes it non-trivial to have var-args. Magic like having a function consume as many further elements as the number on the top of the stack says is of course also possible.

Edit: Oh sorry, I confused "RPL" with "RPN". I don't know about RPL.

comment 7y ago · link · parent

This is a concatenative language, not a Lisp. In Min a function can push and pull an arbitrary number of arguments from the stack. This also makes varargs non-trivial. The round brackets are for creating quotations, and not for executing functions like in Lisp. Maybe the Web-site should make that clearer.

Apparently it doesn't have macros either, it can only manipulate functions.

Edit: Maybe the mods should change the title. @dang