chicken-users
[Top][All Lists]
Advanced

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

Re: Re: [Chicken-users] New to Scheme Macros


From: Jim Ursetto
Subject: Re: Re: [Chicken-users] New to Scheme Macros
Date: Wed, 22 Apr 2009 14:15:22 -0500

2009/4/22  <address@hidden>:
> Thank you, Thomas and John, for the kind replies.
>
> I'm using Chicken 4.
>
> So, I imagine I can stick with syntax-rules until I run into a situation
> where I need something else, at which point I can either try define-macro
> (if I use this, do I need to explicitly gensym?)

A situation not mentioned above where you may prefer something else,
even if not breaking hygiene, is when your macro would be better off
written in procedural style; syntax-rules' exclusive reliance on
pattern matching sometimes leads to byzantine code.  This will be
obvious when you hit it.

define-macro is not available in Chicken 4.  Explicit renaming is
supported by the core.  Documentation on ER is available at
http://chicken.wiki.br/man/4/Modules%20and%20macros#explicit-renaming-macros
.  The eggs and the Chicken core are good places to see working
examples.




reply via email to

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