Re:Show HN: Llr – a Clojure inspired Lisp that compiles to R...
by rcthompson on Saturday November 27, 2021 @01:27PM
(#29362211)
It's not as cursed as you might think. R's semantics are already very lisp-like under the hood.
[ Parent
| on HN ]
Re:Show HN: Llr – a Clojure inspired Lisp that compiles to R...
by bachmeier on Saturday November 27, 2021 @04:52PM
(#29363944)
I'll just point out that R started as a Scheme dialect. If you dig into the source, you'll see that the main C data structure is the SEXP, for s-expression. And as the other comment says, you can call everything as a function. You can write an s-expression form of R in about 30 minutes. Literally all you have to do is identify opening and closing parens and rewrite in `function`(arguments) form.
Re:Show HN: Llr – a Clojure inspired Lisp that compiles to R...
by rackjack on Saturday November 27, 2021 @05:51PM
(#29364402)
Ooooooh wow, I remember digging into R internals a while ago for something and seeing `sexp`, and only NOW am I connecting it to Lisp's SEXP!! That makes so much sense!
Does RData derive from LISP images? Because if so, that'd be quite the revelation to me.
Re:Show HN: Llr – a Clojure inspired Lisp that compiles to R...
by CornCobs on Saturday November 27, 2021 @06:59PM
(#29364845)
RData only stores the environment of the session. It doesn't store the current search path (you need to reload libraries). I believe it's not a full binary image like LISP
Re:Show HN: Llr – a Clojure inspired Lisp that compiles to R...
by lordgroff on Saturday November 27, 2021 @02:09PM
(#29362540)
I submit R is easily the most misunderstood language among programmers.
And it's not just under the hood where it's very lisp like. Heck you can write it with an almost lisp notation if you really wanted to, `+`(1, 2), and the syntax is incredibly pliable. I'm a big fan of lisp and I'd argue it's one dialect of lisp I actually get to use.