From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paul Rubin Newsgroups: gmane.emacs.help Subject: Re: How to cast an imperative loop into a readable recursive function ? Date: Thu, 02 Dec 2010 23:29:34 -0800 Organization: Nightsong/Fort GNOX Message-ID: <7xoc93l3fl.fsf@ruckus.brouhaha.com> References: <7xmxontxan.fsf@ruckus.brouhaha.com> <8a5ef1e1-aab3-47bd-80e3-081f8dc65b0e@c39g2000yqi.googlegroups.com> <84a24d31-6379-4b81-ac65-b0d8642ab7da@37g2000prx.googlegroups.com> <7xfwufmt3b.fsf@ruckus.brouhaha.com> <0c1c00c1-61ef-42be-a2d3-db1ff31035e8@29g2000yqq.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: dough.gmane.org 1291949511 20788 80.91.229.12 (10 Dec 2010 02:51:51 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 10 Dec 2010 02:51:51 +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 03:51:47 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 1PQt5G-0002pQ-V4 for geh-help-gnu-emacs@m.gmane.org; Fri, 10 Dec 2010 03:51:47 +0100 Original-Received: from localhost ([127.0.0.1]:60008 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PQt5G-0003Pi-DX for geh-help-gnu-emacs@m.gmane.org; Thu, 09 Dec 2010 21:51:46 -0500 Original-Path: usenet.stanford.edu!news.glorb.com!news2.glorb.com!news-out.octanews.net!indigo.octanews.net!auth.beige.octanews.com.POSTED!not-for-mail Original-Newsgroups: comp.lang.lisp,comp.emacs,gnu.emacs.help User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) Cancel-Lock: sha1:PIU411kHnIuT8R0sK1qHWA1YrAo= Original-Lines: 15 Original-NNTP-Posting-Date: 03 Dec 2010 01:29:40 CST Original-X-Complaints-To: abuse@octanews.net Original-Xref: usenet.stanford.edu comp.lang.lisp:296050 comp.emacs:100894 gnu.emacs.help:182801 X-Mailman-Approved-At: Thu, 09 Dec 2010 20:09:07 -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:77230 Archived-At: Katalin Sinkov writes: >>       (let ((s ...) (l ...) (p ...) >> ;;; s=start l=length p=?????? I don't mean p is actually a pointer, I just mean p is the offset after your (l=2 s=3) stuff that you matched with a regexp in your original example. > At some stage there will confusion and readability issue. > What strategies are there to grapple with this issue ? Why don't you read some of the Emacs library code? That is basically how I learned Lisp. Or, CL has a real package system so you can do more serious encapsulation. So you could read a CL book and apply the techniques to Emacs Lisp as best you can.