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

They're not really comparable. From the article:

no automagic memory management, no garbage collection, no functional programming




You left out an important bit of context. Lush is garbage collected.

  Lush brings the best of both worlds by wrapping three
  languages into one: (1) a weakly-typed, garbage-
  collected, dynamically scoped, interpreted language with
  a simple Lisp-like syntax, (2) a strongly-typed,
  lexically-scoped compiled language that uses the same
  Lisp-like syntax, and (3) the C language, which can be
  freely mixed with Lush code within a single program, even
  within a single function.
The thing is that Lush the interpreted lisp like language is quite different from CLush the compiled lisp (un)like language. This is indeed an unexpected quirk and gets people who are starting at it. The two, share the same syntax but are quite different languages. CLush can almost be described as C with lisp syntax. What you are referring to is CLush. Lush on the other hand is fully garbage collected. In fact it used to have a reference counting based garbage collector but the developers were looking at other garbage collection algorithms, mainly Boehms garbage collector. I have not used it in a while so I am not sure if it has been baked in. Something I was looking forward to in the new version was parallel loops. There is a stub for that, but it defaulted to the sequential loops in the version I played with. I think a reference counting garbage collector makes parallelism hard to implement, Cpython is perhaps an example of that, whereas Sisal is a counterexample.

Its a fun language to use, it is so much more easier to interface with C (compared to MATLAB, well even Python/Numpy/Scipy sans weave). But there are a few surprises if you expect Lisp.

EDIT: Replying to gaius here to save on deep nests.

Only if you want to distribute it as a compiled binary, (may be to protect your source). You can distribute the source code as is, and it will run just fine. As far as distributing something self contained, I agree that Lush is not tailor made for that. Because even the successfully compiled parts are typically loaded dynamically.


Right, but in Lisp you can use the bottom-up approach to iteratively and interactively build your program, then save image or whatever to get a binary. If your Lush prototype relies on some feature that can't be compiled, you will need to reimplement that before going into production.


[deleted]


More, to have something self-contained without a lot of dependencies, is why I compile.


You're absolutely right -- but it was the decision I had to make.




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

Search: