[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MIT-Scheme-users] Something like "macroexpand" for MIT Scheme?

From: Chris Hanson
Subject: Re: [MIT-Scheme-users] Something like "macroexpand" for MIT Scheme?
Date: Sat, 5 Dec 2015 13:40:12 -0800

It's been a while since I thought about this, but I used to use (pp (syntax-quote ...)) to see the expansion of a macro. I think it still works.

On Fri, Dec 4, 2015 at 7:50 PM, fedekun <address@hidden> wrote:
I apologize if this has been asked before but I can't find anything about it in the archives or googling.

Is there something like Lisp's macroexpand-1 for MIT Scheme? It's quite hard to debug my first macros. How do you guys debug your macros?

Currently I'm just playing around with a macro to define hashes. I want to transform:

(hash '(a 1 b 2))


((lambda ()
  (let ((t make-strong-eq-hash-table))
           (hash-table/put! t 'a 1)
           (hash-table/put! t 'b 2)

For that I worked on this macro, which doesn't work and I'd really love to be able to debug! The idea of the macro is to return a self-executable lambda which returns a reference to a hash-table.

Thanks for your time!

MIT-Scheme-users mailing list

reply via email to

[Prev in Thread] Current Thread [Next in Thread]