<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.0.11" -->
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/">
<channel>
	<title>Comments on: Emacs Lisp vs. Scheme: scoping and globals</title>
	<link>http://www.omnigia.com/news/2007/08/07/emacs-lisp-scoping-globals/</link>
	<description>Scheme, web applications, tech</description>
	<pubDate>Fri, 05 Sep 2008 19:26:56 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.0.11</generator>

	<item>
		<title>by: Dan Muresan</title>
		<link>http://www.omnigia.com/news/2007/08/07/emacs-lisp-scoping-globals/#comment-1520</link>
		<pubDate>Tue, 07 Aug 2007 16:13:24 +0000</pubDate>
		<guid>http://www.omnigia.com/news/2007/08/07/emacs-lisp-scoping-globals/#comment-1520</guid>
					<description>Right, but I was talking about automatic translation from Scheme to Lisp (as CPSCM does).</description>
		<content:encoded><![CDATA[<p>Right, but I was talking about automatic translation from Scheme to Lisp (as CPSCM does).
</p>
]]></content:encoded>
				</item>
	<item>
		<title>by: Pascal Costanza</title>
		<link>http://www.omnigia.com/news/2007/08/07/emacs-lisp-scoping-globals/#comment-1517</link>
		<pubDate>Tue, 07 Aug 2007 11:24:47 +0000</pubDate>
		<guid>http://www.omnigia.com/news/2007/08/07/emacs-lisp-scoping-globals/#comment-1517</guid>
					<description>Try this:


(defmacro deflexrec (&#38;body bindings)
  `(progn
     ,@(loop for var in bindings by #'cddr
             collect `(define-symbol-macro ,var (symbol-value ',var)))
     (setq ,@bindings)
     (values)))

(deflexrec
  f (lambda (x) (funcall g (- x 1)))
  g (lambda (x) (if (&#62; x 0) (funcall f x) 0)))
</description>
		<content:encoded><![CDATA[<p>Try this:</p>
<p>(defmacro deflexrec (&amp;body bindings)<br />
  `(progn<br />
     ,@(loop for var in bindings by #&#8217;cddr<br />
             collect `(define-symbol-macro ,var (symbol-value &#8216;,var)))<br />
     (setq ,@bindings)<br />
     (values)))</p>
<p>(deflexrec<br />
  f (lambda (x) (funcall g (- x 1)))<br />
  g (lambda (x) (if (&gt; x 0) (funcall f x) 0)))
</p>
]]></content:encoded>
				</item>
</channel>
</rss>
