Hacker News new | past | comments | ask | show | jobs | submit login

Could someone explain this bit from the intro to me?

> Recursion is very efficient in the Om language, due to (a) the "eager" evaluation model enabled by prefix concatenative syntax...

How is the syntax of any relevance for the evaluation model?

Once the AST is parsed, the syntax is gone and we're just left with pairs of 'operator' and 'operand'.




Another question about the syntax: Why are the curly braces also part of the syntax for operators? They are delimiters for the operands but also play some part in the definition of operators? Is this solving some problem or did the author just like curlies?


If you're talking about the curly braces after the backtick in the syntax diagram for operators, I think that's just a way to escape those special characters so you can use them in operator names. It would be the same as escaping a double quotation mark in a string literal with a backslash, i.e: "\""


Merci. Thets also the explanation I came up with for myself. And I guess it allows for some trickery with unquoting.


The syntax allows to describe structures in a way that makes the evaluation model efficient, or even possible.

Look at what lengths one has to go constructing a Y combinator when syntax does not allow to refer to the current expression to simply describe recursion.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: