6 ms·
Some thoughts on hylang (2017)
- jessaustin 8y agoMissing some olde lisp things like car/cdr/lambda A quick perusal of hylang.org didn't reveal how a Lisp works without cdr. I'm envisioning something awful with a colon...
- shaunxcode 8y agomore likely car = first and cdr = rest.
- snazz 8y agoCorrect: http://docs.hylang.org/en/stable/language/api.html#rest http://docs.hylang.org/en/stable/language/api.html#rest http://docs.hylang.org/en/stable/language/api.html#first http://docs.hylang.org/en/stable/language/api.html#first
- ebg13 8y ago"posted by cms on 2017-12-31". Has anything significant changed since then?
- kristianp 8y agoSo: (2017)
- JasonFruit 8y agoHy feels all wrong to me, though I really wanted to like it, and I put some time in when I tried it. Part of it is that it compiles to Python bytecode, and took the simplest route of adopting Python's not at all lisplike scope. With `let`, you have a visual clue of variable scope; Hy had a broken `let`, and then got rid of it completely. Now it looks like there's a new `let` that might make more sense. I haven't used it in a couple years. But that's not the only problem. It has the same feeling I get from Clojure and the various lisps that compile to javascript; it just doesn't feel divorced enough from its parent language to be satisfying in itself. I'd rather write lisp than Python, sure, but except for a few libraries I'd like to be able to use, I don't see much reason to prefer Hy over Racket or some other similarly-mature Scheme, which would have somewhat fewer libraries, but would feel like a consistent and self-contained language.
- nicklaf 8y agoI wonder if you might like "Burgled-Batteries" [0], which gives you access to Python objects from Common Lisp. I have not tried it myself, and it does not yet support CLOS integration, but it looks pretty interesting. [0] https://www.cliki.net/burgled-batteries https://www.cliki.net/burgled-batteries
- kazinator 8y agoI suspect the problems of Hy are caused precisely by not compiling to bytecode, but to Python abstract syntax. I suspect that a Lisp that bypasses this syntax and goes right to bytecode could do things better: have a real let and such.
- mark_l_watson 8y agoI feel the same way. I found a nice Hy LSTM demo that uses TensorFlow and had fun playing with that. I did another night of hacking around with Hy and put it in the ‘really interesting, revisit later’ category.
- foobar_ 8y agoI make no shame of it. I am an imperative programmer at heart. Hy is beautifully imperative. return/if/while/break/continue actually work in Hylang. Common Lisp doesn't have these. Scheme purists won't let you have them. Clojure obviously doesn't have them. Let that sink in. The fight against imperative programming has come so far that we banned not just goto but every commonly used control flow primitive. We have banned global variables too and FP purists want to go even further and remove the assignment operator. What is a monad exactly if not the ";" ? What is the end result except more confusing code ? Hylang is a completely distinct lisp and breaks the tradition of all lisps before it. Sibilant is another lisp which does the same but for javascript. What does Hylang do ? It translates almost 1-1 the features of Python onto itself and its a transpiler if I am not mistaken. So you get all the features and libraries of Python without much fanfare. This is such a good idea that we need a C++ version of Hylang. Now if we could get rid of the parens and have begin and end or something like "if .. fi" like civilised folks, that would just be perfect.
- linfocito 8y agoNot disputing the central point, imperative is ok, but Common Lisp has all of it in one or other way - It's pretty much imperative, indeed.
- foobar_ 8y agoHaving started with C at college and then moving onto Common Lisp on my own was a massive headscratch when I first started. I abandoned lisp after that. Common Lisp has tagbody and go of course ... but there is so much shame around it. Why ? How did people learn sh, perl, ruby, python ? By writing dumb imperative scripts of course! Why the shame ? Even from a cursory glance Hylang has more libraries than all the lisps combined. FACT. I think it fits perfectly for scripting tasks and for a change its easier for beginners to get started with. ipdb works with hylang folks! I had to google it. Remember Liskell ? The Lisp that mapped onto Haskell ? I think Hylang and Sibilant should be treated as minimal lisps along the same lines. As compared to Common Lisp .. Hylang is worse and that can only be a good thing.
- willtim 8y ago
- coldtea 8y ago>It's a lisp that compiles? (transpiles? I never get the difference) I've seen others make the same claim. How's the difference difficult to get. It might not be 100% clear-cut and have some edge cases, but in common parlance: Compile -> compiles to executable machine code (or executable bytecode for your VM). Transpile -> produces code in another language (which is then compiled or interpreted or whatever).