From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Peter Keller Newsgroups: gmane.emacs.help Subject: Re: What is the best way to navigate #ifdef and #endif in C program Date: Wed, 4 Aug 2010 15:09:05 +0000 (UTC) Organization: the UPL Message-ID: References: <53f62f81-fb10-4fb6-87ce-0eb5609d12f5@h17g2000pri.googlegroups.com> <87y6cmsmf1.fsf@kuiper.lan.informatimago.com> NNTP-Posting-Host: lo.gmane.org X-Trace: dough.gmane.org 1291953626 2020 80.91.229.12 (10 Dec 2010 04:00:26 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 10 Dec 2010 04:00:26 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Dec 10 05:00:22 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PQu9d-00061G-9f for geh-help-gnu-emacs@m.gmane.org; Fri, 10 Dec 2010 05:00:21 +0100 Original-Received: from localhost ([127.0.0.1]:47374 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PQtx7-000582-RD for geh-help-gnu-emacs@m.gmane.org; Thu, 09 Dec 2010 22:47:25 -0500 Original-Path: usenet.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsgate.cistron.nl!newsgate.news.xs4all.nl!news2.euro.net!feeder.news-service.com!85.214.198.2.MISMATCH!eternal-september.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help,comp.lang.lisp,comp.lang.scheme Original-Lines: 41 Injection-Date: Wed, 4 Aug 2010 15:09:05 +0000 (UTC) Injection-Info: mx01.eternal-september.org; posting-host="ooL5dVz+AwTXWsVFxETc8w"; logging-data="8359"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+Bv0ZQ66MnjsbU1Tad2Jg5" User-Agent: tin/1.9.5-20091224 ("Lochruan") (UNIX) (Linux/2.6.32-24-generic (i686)) Cancel-Lock: sha1:FDXSF9i9uty9/D1+BXOg8OEy8TU= Original-Xref: usenet.stanford.edu gnu.emacs.help:180366 comp.lang.lisp:290888 comp.lang.scheme:87270 X-Mailman-Approved-At: Thu, 09 Dec 2010 20:23:31 -0500 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:77299 Archived-At: In comp.lang.lisp Elena wrote: > On Aug 4, 10:27?am, p...@informatimago.com (Pascal J. Bourguignon) > wrote: >> This is the reason why there is no point asking whether there is a >> feature X in CL. ?You can always add any feature to the language, >> thanks to its macros or reader macros, and metalinguistic abilities in >> general. > > Can macros really add features or can they just add syntactic sugar? A > custom "case" statement is just syntactic sugar, tail call > optimization is a feature. This book: http://letoverlambda.com/index.cl/toc Specifically: http://letoverlambda.com/index.cl/guest/chap5.html#sec_4 Would show you how to write a macro such that it adds Scheme's tail call optimized "named let" into Common Lisp. This goes beyond the concept of syntactic sugar and enters the domain of pure code transformation. So yes, you can add features. However, I don't know if you can add "any" feature to CL. :) For example, could I add the ability for a function to introspect into its own display and see an annotated mapping of the machine registers in context? Or could I ask a piece of memory how many times it has been moved in a generational garbage collector and where was its last physical location? Of course, I could add these things, but not with CL as it exists today since there is no means to get that information outside of implementation specific APIs which extend the meaning and domain of CL. Later, -pete