Arc Forumnew | comments | leaders | submitlogin
2 points by kennytilton 6120 days ago | link | parent

You made me look again at defset, looks promising:

  (mac defset (name parms . body)
    (w/uniq gexpr
      `(sref setter 
           (fn (,gexpr)
             (let ,parms (cdr ,gexpr)
               ,@body))
           ',name)))
An example being:

  (defset car (x)
    (w/uniq g
      (list (list g x)
          `(car ,g)
          `(fn (val) (scar ,g val)))))
I'll try it when I wake up. :)


3 points by kennytilton 6120 days ago | link

Done and committed to CVS. Thx for the push!

-----