(define-record-type foo (make-foo x y) foo? (x foo-x) (y foo-y)) (define-syntax test (ir-macro-transformer (lambda (exp inject compare) (let ((get-x (inject (symbol-append (strip-syntax 'foo) '- (strip-syntax 'x)))) (get-y (inject (symbol-append (strip-syntax 'foo) '- (strip-syntax 'y)))) (body (cdr exp))) `(list ,(get-x body) ,(get-y body)))))) #;215> (test (make-foo 1 2)) Error: during expansion of (test ...) - call of non-procedure: foo-x2352932 Call history: (test (make-foo 1 2)) (inject (symbol-append (strip-syntax (quote foo)) (quote -) (strip-syntax (quote x)))) (symbol-append (strip-syntax (quote foo)) (quote -) (strip-syntax (quote x))) (strip-syntax (quote foo)) (strip-syntax (quote x)) (inject (symbol-append (strip-syntax (quote foo)) (quote -) (strip-syntax (quote y)))) (symbol-append (strip-syntax (quote foo)) (quote -) (strip-syntax (quote y))) (strip-syntax (quote foo)) (strip-syntax (quote y)) (cdr exp) (##sys#list (##core#quote list) (get-x body) (get-y body)) (get-x body) <--