Like Pauan said[1], it's indeed looking punctuation-heavy: http://github.com/akkartik/wart/blob/1f7f6dc405/020.wart Hopefully it'll start looking more sane past the core of the language. --- ssyntax follows the same precedence as arc, but you can do things like this: car:,$f
..which expands to (car ,$f) [2]--- apply has been replaced with eight's splice operator[3]. What used to be this: (apply f args)
now becomes this: (f @args)
In this expression, args is evaluated and spliced into the expression, but f doesn't evaluate it's args a second time. All the arguments were thus evaluated just once, even if f quotes some of its params[4]. def foo(x 'y)
cons x y
with (a 1 b 2)
foo a b
=> (1 . b)
with (a 1 b 2)
foo @'(a b)
=> (a . b)
with (a 1 b 2)
foo @(list a b)
=> (1 . 2)
---The splice operator permits more than apply because args to be spliced don't have to come at the end: (foo @list.a b)
---On my todo list is to figure out a way to replace ,@ with @, and thereby reduce the number of primitives by 1. --- The addr function enables pointer comparison[5]: (iso '(1 2) '(1 2)) ; true like lisp's equal
(iso (addr '(1 2)) (addr '(1 2))) ; false like lisp's eq
---[1] http://arclanguage.org/item?id=15143 [2] $ is the implicit gensym operator: http://arclanguage.org/item?id=13342 [3] The * operator at http://github.com/diiq/eight/blob/master/README [4] Like eight and unlike either lisp or scheme, wart lets functions selectively evaluate just some of their formal parameters. To leave a param unevaluated, just quote it like in the examples above. [5] http://arclanguage.org/item?id=13698 |