The plan was (a) to make a crappy initial version of Arc, (b) use that for a while in real applications, then (c) go back and write a complete, cleaned up language spec, and (d) use that as the basis of a fairly good implementation.
I'm in phase (c) now. I don't know how much longer it will take to finish the spec. It turns out to be quite hard, though very interesting.
That's pretty obsolete. When I wrote that I was in the middle of trying to write a new Arc whose source was as clean as formal semantics but was actual working code. That turned out not to work because the resulting language was so slow I didn't want to use it for anything, and without applications to drive me I stopped caring about the language. What eventually happened after various experiments was that Robert and I wrote a new implementation that was a compromise between cleanness and practicality.
So now instead of starting with cleanness and trying to achieve practicality, the plan is to always work on practical stuff (like "always have running code") but constantly push the source toward cleanness. I feel like a lot of the definitions in arc.arc for example are close to final form.
Isn't destructuring cool? We take an anonymous list and quickly associate useful names with what otherwise would be car, cadr, and caddr, etc.
In common lisp when we use destructuring-bind we can have optional /and/ keyword arguments, so you can plan ahead and create an adhoc list like (1 2 :height 3 :width 4) and let :weight default to 42:
(destructuring-bind (x y &key (height )(width 0)(weight 42))
..etc with x, y, height, width, and weight...)
Hmmm, I think I did that for my Arc implementation of defun...shuffle, shuffle, dig..ah:
(mac defun (name params . body)
(w/uniq (rtargs)
`(def ,name ,rtargs
(withs ,(with (reqs nil key? nil opt? nil keys nil opts nil without)
(each p params
(if (is p '&o) (do (assert (no opt?) "Duplicate &o:" ',params)
(assert (no key?) "&k cannot precede &o:" ',params)
(= opt? t))
(is p '&k) (do (assert (no key?) "Duplicate &k:" ',params)
(= key? t))
key? (push-end p keys)
opt? (push-end p opts)
(do (assert (~acons p) "Reqd parameters need not be defaulted:" p)
(push-end p reqs))))
(with (n -1 kvs (uniq))
(+ (mappend [list _ `(nth ,(++ n) ,rtargs)] reqs)
(mappend [list (carif _) `(or (nth ,(++ n) ,rtargs)
,(cadrif _))] opts)
(list kvs `(pair (nthcdr ,(++ n) ,rtargs)))
(mappend [list (carif _)
`(or (alref ,kvs ',(carif _))
,(cadrif _))] keys)
)))
,@body))))