Pointers are dereferenced by (ptr), so you use (ptr) to get the contents and (= (ptr) v) to assign.
(in-package pointer) (using <arc>v3) ; replace with <hl>v1 (interface v1 pointer) ; replace with (mac (pointer e) ...) (mac pointer (e) (if (acons e) (let vars (map [uniq] e) `(with ,(mappend (fn (var val) `(,var ,val)) vars e) ; replace with (tag...) (annotate 'pointer (cons (fn () ,vars) (fn (v) (= ,vars v)))))) (w/uniq v `(annotate 'pointer (cons (fn () ,e) (fn (,v) (= ,e ,v))))))) ; replace with (defm (sref (t p pointer)... ) ...) (defm sref ((t p pointer) v) ((cdr:rep p) v)) (defcall pointer (p) ((car:rep p)))
(= stuff (list (pointer a) (pointer (car b)) (pointer c!x))) (each p stuff (pr (p)) (= (p) (something)))