Arc Forumnew | comments | leaders | submitlogin
6 points by lojic 5824 days ago | link | parent

I have to admit that Clojure looks very interesting. Functional programming, concurrency with software transactional memory, access to a huge Java library, conciseness, etc. It's also a Lisp-1 like Arc w/ Common Lisp style macros, but it has namespaces. It doesn't have TCO due to JVM limitations and I don't think it has continuations, so an Arc-like web server might be more challenging.

The concurrency story is particularly interesting given the proliferation of cores and slowing of GHz.

The Clojure version of Norvig's spelling corrector appears to be one line shorter than Norvig's Python version:

http://arclanguage.com/item?id=8554

I would really like to see an Arc version of that. I translated Norvig's Python version to Ruby easily, so I expect that someone fluent in Arc could do it easily.

The other Lisp versions I've seen (Scheme/Common Lisp) were quite a bit longer and less elegant IMO.

I'm not super excited about Clojure's dependence on the JVM, but on the other hand, that gives it a huge head start with libraries and state of the art VM/JIT technology.

Rich Hickey doesn't seem to have the star power of pg, but he is very involved in the language and community. He seems like more of a Matz or Guido which doesn't seem that bad - he seems quite sharp in his web cast presentations.

I could be way off, but it seems like it would be easier to add Arc innovations to Clojure than to add Clojure-like concurrency support to Arc.



4 points by almkglor 5823 days ago | link

> continuations, so an Arc-like web server might be more challenging.

Arc's server doesn't actually use continuations - it uses functions that serve as continuatinos. There's no call to 'ccc or any of the wrapping forms in srv.arc (at least none that I remember)

> The concurrency story is particularly interesting given the proliferation of cores and slowing of GHz.

This is true and I think the "extra-cycles-to-waste" property expected by PG isn't going to put out in a hundred years.

> state of the art VM/JIT technology

Forget the libraries. This is what's scary about any JVM language.

-----

1 point by sacado 5823 days ago | link

"Arc's server doesn't actually use continuations - it uses functions that serve as continuatinos. There's no call to 'ccc or any of the wrapping forms in srv.arc (at least none that I remember)"

That's right, no 'ccc. That's why I could implement it so easily in Lua (no real continuation in Lua either). As for TCO, I'm not sure it's a real problem in this case. Sure, a lot of simple functions are written in a recursive style, but they can be trivially rewritten in an iterative style.

-----

2 points by fjl 5804 days ago | link

arc is a movement, not a language.

the primary goal was not to build a language but to get an avalanche of new lisp implementations started.

that lisp is quite easy to implement makes the idea even more compelling.

-----

2 points by Zak 5736 days ago | link

>It doesn't have TCO due to JVM limitations

This is only half-true. Clojure cannot automagically convert a self-call in the tail position in to iteration, but it does have the recur form to provide essentially the same semantics. I've also found it useful that recur throws an exception if used outside of the tail position, making it obvious which recursive forms consume stack space and which do not.

-----