<?xml version="1.0" encoding="utf-8" ?>

<rss version="2.0" 
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:admin="http://webns.net/mvcb/"
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
   xmlns:wfw="http://wellformedweb.org/CommentAPI/"
   xmlns:content="http://purl.org/rss/1.0/modules/content/"
   >
<channel>
    <title>A view from the hill - Programming</title>
    <link>http://hillview.bugwriter.net/</link>
    <description>Blogging Holgers little world</description>
    <dc:language>en</dc:language>
    <generator>Serendipity 1.1 - http://www.s9y.org/</generator>
    <pubDate>Fri, 02 May 2008 12:51:20 GMT</pubDate>

    <image>
        <url>http://hillview.bugwriter.net/templates/default/img/s9y_banner_small.png</url>
        <title>RSS: A view from the hill - Programming - Blogging Holgers little world</title>
        <link>http://hillview.bugwriter.net/</link>
        <width>100</width>
        <height>21</height>
    </image>

<item>
    <title>UCW leadership change</title>
    <link>http://hillview.bugwriter.net/archives/108-UCW-leadership-change.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/108-UCW-leadership-change.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=108</wfw:comment>

    <slash:comments>1</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=108</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    In case you&#039;re interested in continuation-based web development with Common Lisp, it might be of interest to learn that &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=456&amp;amp;entry_id=108&quot;  onmouseover=&quot;window.status=&#039;http://common-lisp.net/pipermail/bese-devel/2008-April/003221.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://common-lisp.net/pipermail/bese-devel/2008-April/003221.html&quot;&gt;Drew Campsie has voluntered to take over UCW development&lt;/a&gt;. Marco Baringer, initiator and maintainer of &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=457&amp;amp;entry_id=108&quot;  onmouseover=&quot;window.status=&#039;http://common-lisp.net/project/ucw/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://common-lisp.net/project/ucw/&quot;&gt;UncommonWeb&lt;/a&gt; (aka UCW) &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=458&amp;amp;entry_id=108&quot;  onmouseover=&quot;window.status=&#039;http://common-lisp.net/pipermail/bese-devel/2008-April/003232.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://common-lisp.net/pipermail/bese-devel/2008-April/003232.html&quot;&gt;seemed somwhat relieved&lt;/a&gt; that finally somebody with more time on his hand steps up to take over. &lt;br /&gt;
&lt;br /&gt;
That Marco hadn&#039;t had the time to keep pushing UCW is quite obvious from the mailing list archive. Lately Attila Lendvai seemed to me (an innocent external observer) to had pushed UCW foreward, however, as he &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=459&amp;amp;entry_id=108&quot;  onmouseover=&quot;window.status=&#039;http://common-lisp.net/pipermail/bese-devel/2008-April/003228.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://common-lisp.net/pipermail/bese-devel/2008-April/003228.html&quot;&gt;Attila announced&lt;/a&gt;, he wants to go into a different direction than Drew.&lt;br /&gt;
&lt;br /&gt;
I&#039;ve been using ucw-dev during the last two years and the current situation really called for a change, in my opinion. UCWs main problem, as I observe it, is lacking documentation and clearly stated goals which way UCW will go. The automatically extracted documentation doesn&#039;t contain information how the bits fit together and &lt;strong&gt;all&lt;/strong&gt; tutorials are a) incomplete, b) outdated as far as they are targetting ucw-dev, whereas development has mainly happened in ucw-ajax. However, it was not all clear that ucw-ajax really would become the main line of UCW. &lt;br /&gt;
&lt;br /&gt;
I like UCWs component architecture a lot and will eagerly follow what is going to happen. With two prominent developers such as Marco and Attila more or less leaving the project, it will be interesting to see with how much activity development will happen from now on.&lt;br /&gt;
 
    </content:encoded>

    <pubDate>Wed, 30 Apr 2008 22:06:42 +0200</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/108-guid.html</guid>
    
</item>
<item>
    <title>Escaping from sql-reader-syntax in CL-SQL</title>
    <link>http://hillview.bugwriter.net/archives/100-Escaping-from-sql-reader-syntax-in-CL-SQL.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/100-Escaping-from-sql-reader-syntax-in-CL-SQL.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=100</wfw:comment>

    <slash:comments>2</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=100</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    This post is mainly a reference post about a particular topic whose solution wasn&#039;t immediately obvious to me from the docs to CL-SQL. Using CL-SQL with (enable-sql-reader-syntax), I had written a routine that looks basically likes this:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
(defun data-by-some-criteria (criteria &amp;key (dbspec +db-spec+)  (dbtype +db-type+))
  (with-database (db dbspec :database-type dbtype :if-exists :old)
    (let (dbresult)
      (if criteria
	  (setq dbresult
		(select &#039;some-model &#039;other-model
			:where [and [= [some.criteria] criteria]
			            [= [some.foreign_id] [other.id]]]
			:order-by &#039;([other.name] [some.foreign_id] 
				          [year] [some.name])
			:database db))
          (setq dbresult
		(select &#039;some-model &#039;other-model
			:where [and [null [some.criteria]]
			            [= [some.foreign_id] [other.id]]]
			:order-by &#039;([other.name] [some.foreign_id] 
				          [year] [some.name])
			:database db))
      (when dbresult
	(loop for (some other) in dbresult
	      collect some)))))
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
This is ugly because the only difference between those two select statements is the check for the criteria, but I had no idea how to combine the two select statements into one, because it&#039;s not possible to embed lisp code (apart from symbols) into an sql-expression (i.e. the type of arguments for :where or :order etc.).&lt;br /&gt;
&lt;br /&gt;
With the next requirement things would become far worse: The order-by statement needs to get more flexible so that it is possible to sort results by year first. Given the approach shown above this would result in at least four select statements, which is horrible. So, naturally I wanted a single select statement with programmatically obtained  :where and :order-by sql expressions.&lt;br /&gt;
&lt;br /&gt;
Step 1: It occured to me that it should be possible to have the arguments in a variable and simply refer to the variable. E.g., using a more simple example:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
(let (where-arg)
  (if (exact-comp-needed)
      (setq where-arg &#039;[= [column] someval])
      (setq where-arg &#039;[like [column] someval]))
  (select &#039;model :where where-arg))
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
So I could now have my two different where-args and two different order-args and use a single select statement. Main problem solved. &lt;br /&gt;
&lt;br /&gt;
Step 2: But for the :where arg in my original problem, only a small fraction of the sql-expression differs. So how do I avoid hard coding the entire value of where-arg? How can I combine some variable part of an sql-expression with some fixed parts? I.e, ultimately I want something like:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
(let (comp-op where-arg)
  (if (exact-comp-needed)
      (setq comp-op &#039;=)
      (setq comp-op &#039;like))
  (setq where-arg &#039;[ &amp;lt;put comp-op here&amp;gt; [column1] someval])
  (select &#039;model :where where-arg))
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
But with CL-SQL modifying the reader, there seems to be no way to make &amp;lt;put comp-op here&amp;gt; work. I didn&#039;t knew how to get the usual variable evaluation into the sql-expression, or how to escape from CL-SQL&#039;s sql-reader-syntax to normal lisp evaluation.  &lt;br /&gt;
&lt;br /&gt;
Somewhere in the back of my head where was that itch that CL-SQL might offer some low-level access to sql expressions. And indeed it does. There are two useful functions, sql-expression and sql-operation. sql-operation &quot;returns an SQL expression constructed from the supplied SQL operator or function operator and its arguments args&quot; (from the cl-sql docs), and we can supply the operator and its arguments from lisp -- which is exactly what I want.&lt;br /&gt;
&lt;br /&gt;
Now, the nice thing is that it&#039;s easy to mix partly handcrafted sql expressions with CL-SQL special sql syntax constructs that will be automatically handled by the reader (if you enable it only via enable-sql-reader-syntax, of course). I.e., for &amp;lt;put comp-op here&amp;gt; we can use sql-operation, but the rest stays essentially the same:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
(let (where-arg)
  (if (exact-comp-needed)
      (setq where-arg (sql-operation &#039;= [column1] someval))
      (setq where-arg (sql-operation &#039;like [column1] someval)))
  (select &#039;model &#039;other-model  :where where-arg))
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
Now, coming back to my original problem, based on this approach I can split out the common part of the :where and :order arguments and combine those with the varying parts as needed and hand them down to a single select statement. Problem solved.&lt;br /&gt;
&lt;br /&gt;
 
    </content:encoded>

    <pubDate>Fri, 22 Feb 2008 12:04:50 +0100</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/100-guid.html</guid>
    
</item>
<item>
    <title>Interactive development gets more popular</title>
    <link>http://hillview.bugwriter.net/archives/99-Interactive-development-gets-more-popular.html</link>
            <category>Programming</category>
    
    <comments>http://hillview.bugwriter.net/archives/99-Interactive-development-gets-more-popular.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=99</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=99</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    It&#039;s interesting to see that more and more environments for interactive development are popping up. If you&#039;re wondering what I&#039;m refering to, it&#039;s what has traditionally been labelled as an interpreter: you get some kind of prompt like in a command shell and can directly enter and run program constructs.  In Ruby, irb is the tool to use, whereas most, if not all, Common Lisp systems provide you a REPL whenever you start-up the system. &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=398&amp;amp;entry_id=99&quot;  onmouseover=&quot;window.status=&#039;http://en.wikipedia.org/wiki/REPL&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://en.wikipedia.org/wiki/REPL&quot;&gt;REPL&lt;/a&gt; is an abbreviation for read-eval-print-loop and this pretty much sums up how interactive development works: you enter some code into the system, and as soon as you hit enter (i.e. finish up the particular line of code), the system will read and evaluate it (&quot;interpret&quot; it, although CL systems may also compile it automatically), presenting you with  the results. &lt;br /&gt;
&lt;br /&gt;
To me, this seems like more people come to understand that the classic edit-compile-debug cycle of traditional compiled languages like C isn&#039;t particular well-suited to a bottum-up programming style, as advocated by the agile programming hype.  Where is the beef? I&#039;ve been told that the reason why the asian folk don&#039;t use forks and knives when dining stems from the opinion that when dining one merely wants to eat, while all handcrafting (like slicing the meat) belongs to the a-priori cooking. The edit-compile-debug cycle tends to produce code more akin to the western steak style, while interactive development tends to produce smaller code parts, all well prepared (read: tested) from the beginning, so you don&#039;t end up with bloody interiors as easily. That&#039;s because of two reasons, I think: In an interactive environment testing a piece of code is cheap and easy. Hack up a small routine and enter it. Next step: call the routine with some sample data. No need to compile. In case there&#039;s an error, you&#039;ll be thrown into the debugger right away. With the traditional edit-compile-debug cycle, you&#039;re gonna edit the code, save it, call the compiler, edit another piece of code testing it, compile that, too, run that and only then you&#039;ll see if it succeeds. This might scare developers from running such tests to often and in result to produce larger routines/code blocks. Second reason: in the interactive environment you&#039;ll typically have somewhat less comfort then in a full-blown editor. So I&#039;m arguing that the slight discomfort will help you in keeping things small because then you&#039;ll not gonna need far reaching edit support.&lt;br /&gt;
&lt;br /&gt;
There is, however, a price to pay: For starters, because your interactive system provides you with a single environment during development, it&#039;s easy to mess it up. That&#039;s different with the traditional edit-compile-debug cycle where every time you compile you run the code in a clean environment. This means, old code refering to refactored functions will result in (usually: compilation)  errors whereas in interactive development you may miss some spot in need for modification because the old refactored code is still around.&lt;br /&gt;
Second, when fiddling with some functions, it may happen that one hacks up several variants, maybe with only slightly differing names or argument lists, so it may happen you forget some crucial code when  finally saving your carefully crafted solution (where saving here typically means copy it over to some editor, not saving an image as you may do in Smalltalk or Lisp). Another thing is that one has to be careful not to confuse bottum-up interactive development with hacking without thinking or design-less programming. This threat is all to common because with an interactive environment it&#039;s just so easy to get started. Unfortunately, without thinking you&#039;ll soon end up with problems one and two and even worse, it&#039;s likely that after a little while nobody (including you, the author) will be able to maintain the resulting code. But if you&#039;re aware of the potential pitfalls, interactive development is a nice way to do explorative programming which avoids a lot of time consuming labour you have to do with the traditional edit-compile-debug cycle.&lt;br /&gt;
&lt;br /&gt;
As a side-note, environments offering incremental compilation like Eclipse aim at a similar goal, but only go  half the way as they only take care of the edit-compile part. Only when one combines that with a test-driven development style you arrive at a similar point, because now the test code, when automatically run, will take care of immediately running the code in question (the eval/print part as far as testing the code is concerned).&lt;br /&gt;
&lt;br /&gt;
To finally come to the reason for this blog post, I was pleased to learn about the &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=399&amp;amp;entry_id=99&quot;  onmouseover=&quot;window.status=&#039;http://www.sukria.net/perlconsole.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://www.sukria.net/perlconsole.html&quot;&gt;Perl Console&lt;/a&gt;, which is &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=400&amp;amp;entry_id=99&quot;  onmouseover=&quot;window.status=&#039;http://www.sukria.net/en/archives/2007/08/29/why-i-wrote-perl-console-or-why-i-dont-use-perl-e-1-d/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://www.sukria.net/en/archives/2007/08/29/why-i-wrote-perl-console-or-why-i-dont-use-perl-e-1-d/&quot;&gt;not the same as the Perl debugger&lt;/a&gt;. I&#039;m eager to try it out, although I&#039;m sure that interactive development with a repl and the executable brain dump that Perl code usually is, is a highly dangerous mix. &lt;br /&gt;
&lt;br /&gt;
&lt;u&gt;Update:&lt;/u&gt; There is also &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=401&amp;amp;entry_id=99&quot;  onmouseover=&quot;window.status=&#039;http://chainsawblues.vox.com/library/post/a-perl-read-excute-print-loop-repl.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://chainsawblues.vox.com/library/post/a-perl-read-excute-print-loop-repl.html&quot;&gt;a series of articles about implementing a REPL in Perl&lt;/a&gt; which may be of interest.&lt;br /&gt;
 
    </content:encoded>

    <pubDate>Fri, 25 Jan 2008 10:14:07 +0100</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/99-guid.html</guid>
    
</item>
<item>
    <title>Twentieth century boys</title>
    <link>http://hillview.bugwriter.net/archives/98-Twentieth-century-boys.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/98-Twentieth-century-boys.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=98</wfw:comment>

    <slash:comments>5</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=98</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    This is just a minor rambling inspired by a &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=389&amp;amp;entry_id=98&quot;  onmouseover=&quot;window.status=&#039;http://groups.google.com/group/comp.lang.lisp/browse_thread/thread/ef6822230da2c706/d448366d4a559cad#d448366d4a559cad&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;recent thread on cll&quot;&gt;recent thread on cll&lt;/a&gt; about the ups and downs of using Rails. What I find really overwhelming is the lack of proofs that other (typically Lisp-based) frameworks really have so much benefit over the established more traditional frameworks (e.g. Rails, Zope, plain PHP, ...). All I can see is starter documents, tutorials etc. that show how to program yet another blog or reddit clone in some particular framework. I miss fair comparisons and detailed discussions why and where exactly that one particular way of doing things has benefits. And especially with regard to those reddit clone prototypes: AFAICT, reddit was far beyond implementing some half-baked prototype (in Lisp) when they decided to switch (to Python). Yes, for demo purposes reinventing the wheel with some unround edges might be acceptable, but in reality only rolling wheels will be sold and this is where the challenge is.&lt;br /&gt;
&lt;br /&gt;
I believe that while it&#039;s nice that frameworks help with implementing your 500 line application, they really need to show their value with large applications. Where is a discussion of a large on-line shopping system in, say, UCW and CL-SQL, with secure shopping over SSL, login handling, input validation, distribution over multiple servers etc.?  Now, I&#039;m not suggesting that UCW, Weblocks etc. can&#039;t be used to build such websites, but it would be nice to see a much more in-depth explanation/discussion/comparison of how to do it. That would also help increase the credibility of Lisp or at least, of lispers discussing (other) web frameworks. 
    </content:encoded>

    <pubDate>Tue, 22 Jan 2008 19:04:00 +0100</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/98-guid.html</guid>
    
</item>
<item>
    <title>CLOS Video in German/auf Deutsch</title>
    <link>http://hillview.bugwriter.net/archives/96-CLOS-Video-in-Germanauf-Deutsch.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/96-CLOS-Video-in-Germanauf-Deutsch.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=96</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=96</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    In case you&#039;re interested in object-oriented programming in Lisp and happen to speak German, you&#039;ll be happy to learn that &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=379&amp;amp;entry_id=96&quot; title=&quot;http://p-cos.blogspot.com/2007/12/reflection-in-potsdam.html&quot;  onmouseover=&quot;window.status=&#039;http://p-cos.blogspot.com/2007/12/reflection-in-potsdam.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Pascal Costanza&lt;/a&gt; of ContextL and AspectL fame (apart of his postings to cll), has given a &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url=aHR0cDovL3d3dy50ZWxlLXRhc2suZGUvcGFnZTUwX2xlY3R1cmUzMzUyLmh0bWw8YnIgLz4NCg==&amp;amp;entry_id=96&quot;  onmouseover=&quot;window.status=&#039;http://www.tele-task.de/page50_lecture3352.html&amp;lt;br /&amp;gt;
&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://www.tele-task.de/page50_lecture3352.html&quot;&gt;talk about CLOS&lt;/a&gt;, the Common Lisp Object System at the Hasso-Plattner Institut, Potsdam. And while we&#039;re at it, Pascal also has a very interesting &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=380&amp;amp;entry_id=96&quot;  onmouseover=&quot;window.status=&#039;http://p-cos.blogspot.com/2007/12/origin-of-advice.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://p-cos.blogspot.com/2007/12/origin-of-advice.html&quot;&gt;blog post about the origins of the advice facility&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
German:&lt;br /&gt;
Falls Dich, lieber Leser, interessiert, wie man objekt-orientiert in Lisp programmiert, solltest Du Dich darüber freuen, dass &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=379&amp;amp;entry_id=96&quot;  onmouseover=&quot;window.status=&#039;http://p-cos.blogspot.com/2007/12/reflection-in-potsdam.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://p-cos.blogspot.com/2007/12/reflection-in-potsdam.html&quot;&gt;Pascal Costanza&lt;/a&gt;, bekannt durch ContextL und AspectL (abgesehen von seinen Postings in cll), einen &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=382&amp;amp;entry_id=96&quot;  onmouseover=&quot;window.status=&#039;http://www.tele-task.de/page50_lecture3352.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://www.tele-task.de/page50_lecture3352.html&quot;&gt;Vortrag in Deutsch über CLOS&lt;/a&gt;, dem Common Lisp Object System, am Hasso Plattner Institut in Potsdam gehalten hat. Und weil wir gerade dabei sind, Pascal hat außerdem einen sehr interessanten &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=380&amp;amp;entry_id=96&quot;  onmouseover=&quot;window.status=&#039;http://p-cos.blogspot.com/2007/12/origin-of-advice.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://p-cos.blogspot.com/2007/12/origin-of-advice.html&quot;&gt;Blogeintrag über die Geschichte von &#039;advice&#039;&lt;/a&gt;.&lt;br /&gt;
 
    </content:encoded>

    <pubDate>Thu, 20 Dec 2007 00:40:02 +0100</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/96-guid.html</guid>
    
</item>
<item>
    <title>Swing the heartache: Interactive DB maintenance in Lisp</title>
    <link>http://hillview.bugwriter.net/archives/93-Swing-the-heartache-Interactive-DB-maintenance-in-Lisp.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/93-Swing-the-heartache-Interactive-DB-maintenance-in-Lisp.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=93</wfw:comment>

    <slash:comments>4</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=93</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    Every now and then, I&#039;m still blown away by the elegant power that the repl (read-eval-print-loop) of Common Lisp provides for everyday tasks. A recent example: I needed to fix a broken column definition in one of my Postgres databases. I&#039;m not a DB pro, so I will just drop the column. But of course, we want to retain the old data, so here we go (using CL-SQL):&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;
&lt;code&gt;
SOMEDB&gt; (connect +db-spec+)
#&lt;CLSQL-POSTGRESQL-SOCKET:POSTGRESQL-SOCKET-DATABASE localhost/db/schauer OPEN {D8EABF1}&gt;
SOMEDB&gt; (defvar *olddata* (select [id] [data] :from [sometable]))
*OLDDATA*
SOMEDB&gt; (execute-command &quot;ALTER TABLE sometable DROP COLUMN data;&quot;)
NIL
SOMEDB&gt; (execute-command &quot;ALTER TABLE sometable ADD COLUMN data varchar;&quot;)
NIL
SOMEDB&gt; (loop for (id value) in *olddata*
                  do (update-records [sometable] 
                                 :attributes &#039;(data) 
                                 :values (list value) 
                                 :where [= [id] id]))
NIL
SOMEDB&gt; (disconnect)
&lt;/code&gt;
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
That&#039;s it. First we open a connection, store away the olddata (which will be returned as a list of tuples) in a global variable, modify the table and finally restore the data. Now, what I find really nice about this is that I can operate on the data as if I had an intersection of psql, shell and a real programming language, which is pretty much the point of this blog post. I think that Ruby probably provides a similar environment with irb. And, hey, today I learned that XEmacs comes with an interface to postgres, so I might have been able to do it from within my favourite editor, too ... 
    </content:encoded>

    <pubDate>Wed, 21 Nov 2007 23:16:16 +0100</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/93-guid.html</guid>
    
</item>
<item>
    <title>Lisp golf</title>
    <link>http://hillview.bugwriter.net/archives/90-Lisp-golf.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/90-Lisp-golf.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=90</wfw:comment>

    <slash:comments>11</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=90</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    Some time &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=342&amp;amp;entry_id=90&quot;  onmouseover=&quot;window.status=&#039;http://hillview.bugwriter.net/archives/78-Splitting-the-dark-side-....html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;Splitting the dark side&quot;&gt;ago&lt;/a&gt;, I was looking at splitting some text with Elisp, Perl, Ruby and Common Lisp. Yesterday, when I again had to do quite the same thing, it occurred to me that the Common Lisp solution was unnecessary complex/long. I&#039;m not a Perl guru, but I believe the following is probably hard to beat even with Perl:&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;
&lt;code&gt;
CL-USER&gt; (format t &quot;~{&amp;lt;li&amp;gt;~A&amp;lt;/li&amp;gt;~%~}&quot; (cl-ppcre:split &quot;\\|&quot; &quot;Kim Wilde|Transvision Vamp|Ideal|Siouxsie and the Banshees|Nena|Iggy Pop&quot;))

&amp;lt;li&amp;gt;Kim Wilde&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;Transvision Vamp&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;Ideal&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;Siouxsie and the Banshees&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;Nena&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;Iggy Pop&amp;lt;/li&amp;gt;
NIL
&lt;/code&gt;
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
For the uninitiated, it&#039;s not the cl-ppcre library which is interesting here but the built-in iteration facilities of format. See the &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=343&amp;amp;entry_id=90&quot;  onmouseover=&quot;window.status=&#039;http://www.lisp.org/HyperSpec/Body/sec_22-3-7.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://www.lisp.org/HyperSpec/Body/sec_22-3-7.html&quot;&gt;Hyperspec on the control-flow features of format&lt;/a&gt; for details. Now, I usually tend to avoid the mini languages that come with Common Lisp like the one of format or loop when writing real programs, but when using Lisp as a glorified shell they come in very handy. 
    </content:encoded>

    <pubDate>Fri, 09 Nov 2007 09:33:43 +0100</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/90-guid.html</guid>
    
</item>
<item>
    <title>Automated unit testing via ASDF?</title>
    <link>http://hillview.bugwriter.net/archives/88-Automated-unit-testing-via-ASDF.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/88-Automated-unit-testing-via-ASDF.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=88</wfw:comment>

    <slash:comments>2</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=88</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    Dear Lazyweb, I&#039;m looking for a way to automate unit testing with the help of ASDF. I&#039;m using &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=337&amp;amp;entry_id=88&quot;  onmouseover=&quot;window.status=&#039;http://www.cliki.net/xlunit&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://www.cliki.net/xlunit&quot;&gt;XLUNIT&lt;/a&gt; at the moment, but this isn&#039;t really relevant. What I want to achieve is that on every compilation of some source file, it&#039;s corresponding test file will be loaded (and hence the tests it contains run). However, what I seek to avoid is simply adding the test files to the component definition; the test files should be kept separately. From what I gather from the ASDF documentation, this should be possible using :perform forms, but the very same docs leave me wondering how. What I found (looking at Jörg Höhles asdf file for iterate) is how to load and run a complete test-system, but this is not what I want to do. Ideally, I would like to have a single perform instruction looking something like this:&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;
&lt;code&gt;
(defmethod asdf:perform ((op test-op) c)
  (when (asdf:glorified-find-component &quot;my-component&quot; c)
        (let ((component-test (find-component-test c)))
            (when component-test
                   (asdf:operate &#039;asdf:load-op &#039;component-test)))))
&lt;/code&gt;
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Here &lt;code&gt;#&#039;glorified-find-component&lt;/code&gt; needs to recursively follow the components parent and &lt;code&gt;#&#039;find-component-test&lt;/code&gt; should return a component &lt;code&gt;c-test&lt;/code&gt; (with c expanded, obviously). Now, I guess I&#039;m just clumsily reinventing the wheel and hence I&#039;m wondering if somebody has already solved &quot;the problem&quot;.&lt;br /&gt;
&lt;br /&gt;
While I&#039;m at it (it referring to testing), &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=338&amp;amp;entry_id=88&quot;  onmouseover=&quot;window.status=&#039;http://common-lisp.net/project/stefil/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://common-lisp.net/project/stefil/&quot;&gt;Stefil&lt;/a&gt; looks like a very interesting test environment in case you&#039;re developing your programs with Emacs and &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=339&amp;amp;entry_id=88&quot; title=&quot;http://common-lisp.net/project/slime/&quot;  onmouseover=&quot;window.status=&#039;http://common-lisp.net/project/slime/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;&gt;Slime.&lt;/a&gt; From there,  I found a link to &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=340&amp;amp;entry_id=88&quot;  onmouseover=&quot;window.status=&#039;http://aperiodic.net/phil/archives/Geekery/notes-on-lisp-testing-frameworks.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://aperiodic.net/phil/archives/Geekery/notes-on-lisp-testing-frameworks.html&quot;&gt;Phil Gregory&#039;s test framework comparison&lt;/a&gt; which I found much more enlightening than the &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=341&amp;amp;entry_id=88&quot;  onmouseover=&quot;window.status=&#039;http://wiki.alu.org/Test_Frameworks&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://wiki.alu.org/Test_Frameworks&quot;&gt;ALUs list of test frameworks&lt;/a&gt;. 
    </content:encoded>

    <pubDate>Tue, 06 Nov 2007 00:54:00 +0100</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/88-guid.html</guid>
    
</item>
<item>
    <title>Now I'm all over the shop ... or Converting from RCS to Mercurial</title>
    <link>http://hillview.bugwriter.net/archives/87-Now-Im-all-over-the-shop-...-or-Converting-from-RCS-to-Mercurial.html</link>
            <category>Programming</category>
    
    <comments>http://hillview.bugwriter.net/archives/87-Now-Im-all-over-the-shop-...-or-Converting-from-RCS-to-Mercurial.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=87</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=87</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    Like I mentioned in a previous post (&lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=348&amp;amp;entry_id=87&quot;  onmouseover=&quot;window.status=&#039;http://hillview.bugwriter.net/archives/54-Fire-it-up.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://hillview.bugwriter.net/archives/54-Fire-it-up.html&quot;&gt;here&lt;/a&gt;), I hadn&#039;t looked closer at those modern distributed revision control systems like Git, Darcs or Mercurial. This was mainly due to two facts: As I&#039;m currently neither involved in any major open source project which uses these systems nor in a project at work which requires the facilities offered by such systems, and as there was no easy access for them in XEmacs, the more traditional systems like Subversion, CVS and RCS are fine for me. However, there was this nag that I might miss something and as revision systems always have been somewhat of a pet peeve of mine, I eventually spend some time reading up more on them. I&#039;ve read quite a lot of discussions on the web, and gathered that mercurial might be worth a closer look, as it claims to be quite easy to handle, comparably well documented and quite fast. And then finally I&#039;ve read on xemacs-beta that the new vc package (in Pre-Release) would support mercurial as well.&lt;br /&gt;
&lt;br /&gt;
Well, that&#039;s where I am now: I have several pieces of code lying around which I sometimes develop on my main machine and sometimes on my laptop when moving around. This is the scenario where a server-based approach to revision control is not what you want: you won&#039;t be able to access your server while you&#039;re on the road and hence you can&#039;t commit. Now, with RCS that&#039;s not a problem, as there is no server involved. But of course, since RCS is a file-system local revision system, syncing is a major problem and you have to go to great pains to ensure you don&#039;t overwrite changes you made locally in between syncs. I hope that a distributed version control system like mercurial will solve the problem, as I no longer have to decide which version is the current head version, instead cherry-picking change sets at will.&lt;br /&gt;
&lt;br /&gt;
But of course, for this to happen, I have to convert my RCS repositories to Mercurial. This doesn&#039;t seem to be a common problem: there are a lot of tools for conversion from CVS or Subversion (see &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=349&amp;amp;entry_id=87&quot;  onmouseover=&quot;window.status=&#039;http://www.selenic.com/mercurial/wiki/index.cgi/RepositoryConversion&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://www.selenic.com/mercurial/wiki/index.cgi/RepositoryConversion&quot;&gt;Mercurial Wiki&lt;/a&gt;, e.g. &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=350&amp;amp;entry_id=87&quot;  onmouseover=&quot;window.status=&#039;http://wiki.darcs.net/DarcsWiki/Tailor&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://wiki.darcs.net/DarcsWiki/Tailor&quot;&gt;Tailor&lt;/a&gt; for instance), but not from RCS. I ended up following the instructions given in the &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=351&amp;amp;entry_id=87&quot;  onmouseover=&quot;window.status=&#039;http://twiki.org/cgi-bin/view/Plugins/MercurialContrib&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://twiki.org/cgi-bin/view/Plugins/MercurialContrib&quot;&gt;TWiki Mercurial Contribution page&lt;/a&gt;. I have some minor corrections, though, so here we go: &lt;br /&gt;
&lt;br /&gt;
-1. (Step 6 in TWiki docs) Ensure all your files are checked in RCS. I won&#039;t copy the advice from the TWiki page here, because I believe in meaningful commit messages and would urge you to do a manual check.&lt;br /&gt;
&lt;br /&gt;
0. You&#039;ll need cvs20hg and rcsparse which you will find &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=352&amp;amp;entry_id=87&quot;  onmouseover=&quot;window.status=&#039;http://ww2.fs.ei.tum.de/~corecode/hg/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://ww2.fs.ei.tum.de/~corecode/hg/&quot;&gt;here&lt;/a&gt;. You&#039;ll need to have Python development libraries installed, i.e. Python.h. For Debian systems, this is in package python-dev. Installation is as simple as two &quot;./setup install&quot; as root which will install the relevant libraries and Python scripts.&lt;br /&gt;
&lt;br /&gt;
1. Create a new directory for your new mercurial repository (named REPO-HG, replace that name):&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
    mkdir REPO-HG
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
2. Initialize the repository:&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
   hg init REPO-HG
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
3. (Step 4 in the TWiki document) Create a new copy of your old RCS repository (named REPO here, replace that with the name containing your old RCS files), add a CVSROOT and a config file  (mistake one in the TWiki docs: As with all CVS data, the &quot;config&quot; file needs to go to CVSROOT, not to CVSROOT/..). Of course, if you&#039;re no longer interested in your old data, you may omit the initial copy.&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
    mkdir tmp
    cp -ar REPO tmp/REPO-old
    mkdir tmp/CVSROOT
    touch tmp/CVSROOT/config
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
4. Inside your directory with the old RCS data, move everything out of the RCS subdirectories&lt;br /&gt;
    (mistake two in the TWiki docs: the double-quotes need to go before the asterix):&lt;br /&gt;
 &lt;code&gt;
&lt;pre&gt;
   find tmp/REPO-old -type d -name RCS -prune | while read r; do mv -i &quot;$r&quot;/* &quot;$r/..&quot;; rmdir &quot;$r&quot;; done
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
    &lt;br /&gt;
5.  Run cvs20hg to copy your old repository to mercurial. If you don&#039;t follow the directory scheme shown below, you&#039;ll end up with your new mercurial repository missing the initial letter of the name of all top-level files and directories.&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
   cvs20hg tmp/REPO-old `basename tmp/REPO-old` REPO-HG
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
6. Check that everything looks like you would expect:&lt;br /&gt;
&lt;code&gt;&lt;br /&gt;
&lt;pre&gt;
   cd REPO-HG
   hg log
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
7. If you had files in your old directory not under version control that you&#039;ll like to keep, copy them over. This might be a good time to think about whether they are worth having them under revision control. Afterwards throw away any old directory you no longer need (i.e., your original REPO, tmp/*).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 
    </content:encoded>

    <pubDate>Wed, 17 Oct 2007 20:20:51 +0200</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/87-guid.html</guid>
    
</item>
<item>
    <title>Programming languages I know</title>
    <link>http://hillview.bugwriter.net/archives/80-Programming-languages-I-know.html</link>
            <category>Programming</category>
    
    <comments>http://hillview.bugwriter.net/archives/80-Programming-languages-I-know.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=80</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=80</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=291&amp;amp;entry_id=80&quot;  onmouseover=&quot;window.status=&#039;http://kitenet.net/~joey/languages/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://kitenet.net/~joey/languages/&quot;&gt;Joey&lt;/a&gt; seems to have inspired a &quot;list of programming languages you know&quot;-contest over on &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=292&amp;amp;entry_id=80&quot; title=&quot;http://planet.debian.org/&quot;  onmouseover=&quot;window.status=&#039;http://planet.debian.org/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; &gt;planet.debian.org&lt;/a&gt;, so this is mine:&lt;br /&gt;
&lt;br /&gt;
&lt;ol&gt;&lt;br /&gt;
&lt;li&gt;Basic (forgotten)&lt;br /&gt;
       I&#039;ve started using Basic on the Commodore C64 and have used it considerably, apart from the intrinsics of peek and poke, which some would claim was what Basic on the C64 was all about. I also used Basic on the Apple II at school, but was spared any further need to use Basic.&lt;br /&gt;
&lt;li&gt;Cobol (forgotten)&lt;br /&gt;
       I remember my old computer science teacher bringing white and green prints on endless paper and teaching us the joys of Cobol. Having used Basic before, it looked somewhat suspicious but not too alien. Fortunately, we only had to solve some simple problems on paper, as the Apple II only had .... DBase II, I think.&lt;br /&gt;
&lt;li&gt;Pascal (forgotten)&lt;br /&gt;
       (Turbo) Pascal was the language of choice in the first semester at the University of Koblenz at the start of the nineties. I&#039;ve did what I had to do in it, but never really liked it. From the occasional look I throw in Wirth&#039;s algorithms book I know I can still read it, but the language looks just as baroque as the copy of the book I have.&lt;br /&gt;
&lt;li&gt;Prolog (forgetting)&lt;br /&gt;
       I&#039;ve really done a lot in Prolog, being first exposed in the second semester to it. I remember to marvel at some guys who grokked the language at first usage in the initial course -- to me, having used only imperative languages up to then, it was a mistery. I still think Richard A.O&#039;Keefe&#039;s book &quot;The Craft of Prolog&quot; is among the best CS books.&lt;br /&gt;
&lt;li&gt;C/C++ (forgetting)&lt;br /&gt;
       About 1992, I somehow got interested in object-oriented programming. Free software was still unknown to me, so I bought a student edition of Turbo C++ and some Addison-Wesley book and of I went inventing another wheel. At the time, I also had to do some C hacking for some course at the university, involving MS Windows programming. I&#039;ve used C over time in several smaller projects, but would never call myself a C hacker.&lt;br /&gt;
&lt;li&gt;Assembler (forgotten)&lt;br /&gt;
     My first exposure to Assembler was with some book for the C64. I was very interested but understood next to nothing. I should program some I/O chip directly instead of just using &quot;load $,8,1&quot;? WTF? Next look was in University, of course. I still know enough bits to be able to grok more or less the output of &lt;code&gt;(disassemble &#039;foo)&lt;/code&gt; of some (tiny) foo-function in CL on an i386-style machine, but that&#039;s about it.&lt;br /&gt;
&lt;li&gt;Mercury (had interest in)&lt;br /&gt;
      Mercury seemed like a nice successor to Prolog, adding several features of functional languages. I read several manuals, had several installations and never used it for anything.&lt;br /&gt;
&lt;li&gt;Life (had interest in)&lt;br /&gt;
      Another possible successor to Prolog, which I&#039;ve learned about at a summer school for language, logics and information. That&#039;s about all I remember.&lt;br /&gt;
&lt;li&gt;XLisp (forgotten)&lt;br /&gt;
      My first exposure to Lisp in the context of a course for computational linguistics. The only thing worse than the editor used in the system was the tutor giving the course. A horror of parenthesis is about the only thing I remember.&lt;br /&gt;
&lt;li&gt;Shell scripting (daily usage)&lt;br /&gt;
      I think since 1992 or 93 I&#039;ve been using Unix systems and shell scripts. I no longer can remember whether our Suns dumped you into csh or sh or whatever, but since I&#039;ve been using Linux systems (since 94), I&#039;ve been using bash and written bourne shell scripts. Of course, I&#039;ve also written the occasional csh script abdomination, but &quot;Csh programming considered harmful&quot; was an early lecture.&lt;br /&gt;
&lt;li&gt;Emacs Lisp (forgetting)&lt;br /&gt;
     I remember seeing one of my instructors doing nearly miracles with XEmacs and wondering how his fingers could be that flexible -- I know that now. &lt;img src=&quot;http://hillview.bugwriter.net/templates/default/img/emoticons/smile.png&quot; alt=&quot;:-)&quot; style=&quot;display: inline; vertical-align: bottom;&quot; class=&quot;emoticon&quot; /&gt; I&#039;ve written several small utilities in Elisp and keep using it occasionally.&lt;br /&gt;
&lt;li&gt;Common Lisp (improving)&lt;br /&gt;
      When I started a student job in 1995, I also started using Common Lisp, using Steele&#039;s CLtL2. Having used Elisp before, I no longer was worried about parenthesis. I still keep finding areas I didn&#039;t know or used before. And it&#039;s a language large enough that keeps you re-learning tricks you thought you knew. Which didn&#039;t stop me from giving a course on CL, which in hindsight didn&#039;t have the right focus: instead of showing that CL is just as capable of doing whatever you expect, it&#039;s also capable of doing you won&#039;t expect.&lt;br /&gt;
&lt;li&gt;Smalltalk (interested)&lt;br /&gt;
     At the computational linguistics lab in Freiburg, the parser system was implemented in Smalltalk, so when I started there I took a small course in Smalltalk. As I worked more on the knowledge representation side of the system, I only rarely used it, though, so rare indeed, that I never got to do anything serious with the language. I still can read Smalltalk despite it&#039;s somewhat unusal syntax and have to do that even sometime.&lt;br /&gt;
&lt;li&gt;Tcl (forgotten)&lt;br /&gt;
    We wanted to extend a linguistic annotation written in Tcl, so I bought a book and started digging through the code. Soon enough a student took over the job (and did it rather well), so I started the tiny bits I&#039;ve learned quite soon. I remember finding the concept that every thing is a string to be rather messy and still see it as a lame excuse for dynamic/weak typing.&lt;br /&gt;
&lt;li&gt;Perl (static)&lt;br /&gt;
    For nearly ten years, I had been using shell and/or Emacs to solve any data mangling tasks when I finally gave in and had a closer look at Perl. I still find it amazing how quick and dirty it&#039;s possible to solve problems in Perl, but on the other hand I&#039;ve given up Perl for more complex tasks that require some thought and design, since Perl&#039;s syntax and language idiosyncrasies keep leading me to programs I don&#039;t even like myself.&lt;br /&gt;
&lt;li&gt;XSLT (improving)&lt;br /&gt;
    At about the same time I started using Perl, I also needed to transform a set of XML documents and XSLT was all over the media, so I had a closer look. I dislike the noisy syntax of XSLT and particular the intermix with output elements and it&#039;s fever for being a &quot;clean&quot; functional language. But the concept of XPath and the idea of traversing a document via axis  I find very compelling.   &lt;br /&gt;
&lt;li&gt;make (static)&lt;br /&gt;
   For a long time the power of make didn&#039;t occur to me. A colleague of mine, however, used it to implement a nifty workflow for document processing, of which I learned a lot of tricks when I needed to mimic it for a different task.&lt;br /&gt;
&lt;li&gt;Ruby (improving)&lt;br /&gt;
   When I finally was &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=293&amp;amp;entry_id=80&quot; title=&quot;http://hillview.bugwriter.net/archives/10-Do-the-do.html&quot;  onmouseover=&quot;window.status=&#039;http://hillview.bugwriter.net/archives/10-Do-the-do.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; &gt;fed up with Perl&lt;/a&gt;, I looked around to find Ruby as a nice halfway compromise between Common Lisp and Perl. It&#039;s still fancy and geeky and with Ruby on Rails has a lot of buisness ballyhoo around it, so I hope it will see more use in my current surrounding.&lt;br /&gt;
&lt;li&gt;Java (not interested)&lt;br /&gt;
   Like everybody else, I couldn&#039;t avoid looking at Java. It seems to be the Cobol of today and as such is the job guarantee today. But Java looks &lt;strong&gt;so&lt;/strong&gt; boring, I can hardly stand it. And this with regard to both the language and the results produced with it. &lt;strong&gt;Sigh&lt;/strong&gt; But still, it&#039;s likely that someday I&#039;ll going to buy another book (that would be my third Java book, the first being O&#039;Reilly&#039;s Java in a nutshell for Java 1.1 in maybe 1997 or so?), since just like Cobol at it&#039;s time, avoiding Java is hard ...&lt;br /&gt;
&lt;li&gt;Python (not interested)&lt;br /&gt;
  When Python 1.4 hit the scene, there was quite some bubble around it. It burst quickly and as my latest review of the language reveiled last year, it still doesn&#039;t seem interesting.&lt;br /&gt;
&lt;/ol&gt;&lt;br /&gt;
&lt;br /&gt;
Missing in this list is stuff like Scheme, Dylan, Oz, Oberon, Eiffel, Haskell and probably some other &quot;tiny&quot; languages which I looked at at some point in time and really didn&#039;t ever took a second look. Of those, I may take another look at Haskell in the future, but currently I have no concrete plans in doing so. 
    </content:encoded>

    <pubDate>Mon, 13 Aug 2007 19:38:00 +0200</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/80-guid.html</guid>
    
</item>
<item>
    <title>How much playing time does your MP3 collection have?</title>
    <link>http://hillview.bugwriter.net/archives/79-How-much-playing-time-does-your-MP3-collection-have.html</link>
            <category>Linux</category>
            <category>Programming</category>
    
    <comments>http://hillview.bugwriter.net/archives/79-How-much-playing-time-does-your-MP3-collection-have.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=79</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=79</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    I love the Unix toolbox: &lt;br /&gt;
&lt;br /&gt;
[elendil-&gt;Get_the_gore]mp3info -p &quot;%S\t%m:%02s\t%t\n&quot; * | perl -ne &#039;{ $time=$time+$1 if (/^(\d+)[ \t]+(.*)$/); print $2.&quot;\n&quot;; } END { print &quot;Total seconds: $time\n&quot;; $min=$time/60; $secs=$time%60; print(sprintf(&quot;Total time: %d:%d\n&quot;,$min,$secs)); }&#039;&lt;br /&gt;
2:10    Fox in a box&lt;br /&gt;
3:16    Loaded heart&lt;br /&gt;
2:53    All grown up&lt;br /&gt;
3:07    Pleasure unit&lt;br /&gt;
2:51    Where evil grows&lt;br /&gt;
3:16    Casino&lt;br /&gt;
2:38    Don&#039;t cry&lt;br /&gt;
2:24    Mary Ann&lt;br /&gt;
3:48    You lied to me before&lt;br /&gt;
1:50    So sophisticated&lt;br /&gt;
2:50    Little baby&lt;br /&gt;
2:44    Sweet potato&lt;br /&gt;
2:56    Voodoo doll&lt;br /&gt;
1:51    Hammer stomp&lt;br /&gt;
Total seconds: 2314&lt;br /&gt;
Total time: 38:34&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Printing out the track number and the track title works only if the file contains an ID3 tag, of course. 
    </content:encoded>

    <pubDate>Fri, 10 Aug 2007 11:42:22 +0200</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/79-guid.html</guid>
    
</item>
<item>
    <title>Splitting the dark side ...</title>
    <link>http://hillview.bugwriter.net/archives/78-Splitting-the-dark-side-....html</link>
            <category>Emacs</category>
            <category>Lisp</category>
            <category>Programming</category>
    
    <comments>http://hillview.bugwriter.net/archives/78-Splitting-the-dark-side-....html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=78</wfw:comment>

    <slash:comments>6</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=78</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    For a review, I needed to get the track list of a given CD. As the track list wasn&#039;t available via CDDB, I went to &lt;i&gt;some large online store&lt;/i&gt; and found the tracklist. I need to convert it to XML, though. The original data I fetched looks like so:&lt;br /&gt;
&lt;br /&gt;
1. Fox In A Box&lt;br /&gt;
2. Loaded Heart&lt;br /&gt;
3. All Grown Up&lt;br /&gt;
4. Pleasure Unit&lt;br /&gt;
...&lt;br /&gt;
&lt;br /&gt;
whereas I need:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li id=&quot;1&quot;&amp;gt;Fox In A Box&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li id=&quot;2&quot;&amp;gt;Loaded Heart&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li id=&quot;3&quot;&amp;gt;All Grown Up&amp;lt;/li&amp;gt;&lt;br /&gt;
...&lt;br /&gt;
&lt;br /&gt;
After cutting the original data to my Emacs, writing out a simple file and using Perl for that simple transformation seemed just gross. In the past, I&#039;ve been an Emacs hacker. But no more, or so it seems, since it took me nearly half an hour just to come up with this simple function:&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
(defun tracklist-to-li (point mark)
  &quot;Generate a string with &amp;lt;li&amp;gt;-elements containing tracks.
Assumes that one every line of region, a track position 
and the track name is given.&quot;
  (interactive &quot;r&quot;)
  (save-excursion 
    (goto-char point)
    (let ((current-pos (point))
	  (result &quot;&quot;))
      (while (re-search-forward &quot;^\\([0123456789]+?\\)\.[ \t]+\\(.*\\)$&quot; 
				mark t)
	(setq result
	      (concat result
		      &quot;&amp;lt;li id=\&quot;&quot;
		      (match-string 1)
		      &quot;\&quot;&amp;gt;&quot;
		      (match-string 2)
		      &quot;&amp;lt;/li&amp;gt;\n&quot;))
	(setq current-pos (point)))
      (message result))))
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
What took the most time was that I&#039;ve had forgotten to escape the grouping parenthesis in the regular expression and that it took me a little while to accept that there is really no \d or equivalent character class in Emacs regexps. Which probably means that I&#039;ve been doing too much in Perl, sed and the like. OTOH, it just may hint at the horror of regular expressions handling in Emacs. What I also dislike is that whenever you want some result in Emacs and see it, too, you have to invoke an interactive operation like &lt;code&gt;message&lt;/code&gt;. Of course, there is IELM,  but this doesn&#039;t really help you for interactive functions operating on regions.&lt;br /&gt;
&lt;br /&gt;
And five minutes later, I realize I need to convert some string like &quot;The (International) Noise Conspiracy|The&lt;br /&gt;
Hi-Fives|Elastica&quot; into a similar list structure. With a simple cut &amp;amp; paste and roughly 30 seconds later, I have&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
[bauhaus-&gt;~]perl -e &#039;$a=&quot;The (International) Noise Conspiracy|The Hi-Fives|Elastica&quot;; @a=split(&quot;\|&quot;,$a); 
foreach $b  (sort @a) { print &quot;&amp;lt;li&amp;gt;$b&amp;lt;/li&amp;gt;\n&quot;; }&#039;
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
Hmm. Perhaps I&#039;ve come quite a long way on the dark side already ...&lt;br /&gt;
&lt;br /&gt;
On the other hand, in Ruby, this is just as simple (I&#039;m using irb, the interactive ruby shell here):&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
irb(main):008:0&gt; a=&quot;The (International) Noise Conspiracy|The Hi-Fives|Elastica&quot;
=&gt; &quot;The (International) Noise Conspiracy|The Hi-Fives|Elastica&quot;
irb(main):009:0&gt; a.split(&quot;|&quot;).each {|string|
irb(main):010:1* print &quot;&amp;lt;li&amp;gt;&quot;
irb(main):011:1&gt; print string
irb(main):012:1&gt; print &quot;&amp;lt;/li&amp;gt;\n&quot;
irb(main):013:1&gt; }
&amp;lt;li&amp;gt;The (International) Noise Conspiracy&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;The Hi-Fives&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;Elastica&amp;lt;/li&amp;gt;
=&gt; [&quot;The (International) Noise Conspiracy&quot;, &quot;The Hi-Fives&quot;, &quot;Elastica&quot;]
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
The difference here is the implicit array Ruby generates, which of course in Perl you could hide in the array position of the foreach loop. Note the annyoing misfeature of irb to always show the prompt even when your still continuing your current input line.&lt;br /&gt;
&lt;br /&gt;
In Common Lisp we can do it just as short:&lt;br /&gt;
&lt;code&gt;
&lt;pre&gt;
CL-USER&gt; (let* ((a &quot;The (International) Noise Conspiracy|The Hi-Fives|Elastica&quot;)
		          (splits (ppcre:split &quot;\\|&quot; a)))
	           (loop
      	              for string in splits
	              do 
	                  (format t &quot;&amp;lt;li&amp;gt;~S&amp;lt;/li&amp;gt;~%&quot; string)))
&amp;lt;li&amp;gt;&quot;The (International) Noise Conspiracy&quot;&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;&quot;The Hi-Fives&quot;&amp;lt;/li&amp;gt;
&amp;lt;li&amp;gt;&quot;Elastica&quot;&amp;lt;/li&amp;gt;
NIL
&lt;/pre&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
The same thing here: The result of the split could have been easily embedded in the loop.&lt;br /&gt;
&lt;br /&gt;
The lesson, of course, is that in the end this example only serves to show that things that are easy to achieve in a high-level are indeed easy to achieve. Or to put it otherwise that the use of regular expressions is no more a discriminating feature between programming languages. 
    </content:encoded>

    <pubDate>Wed, 08 Aug 2007 23:34:14 +0200</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/78-guid.html</guid>
    
</item>
<item>
    <title>Here's your XSL</title>
    <link>http://hillview.bugwriter.net/archives/77-Heres-your-XSL.html</link>
            <category>Programming</category>
    
    <comments>http://hillview.bugwriter.net/archives/77-Heres-your-XSL.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=77</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=77</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=246&amp;amp;entry_id=77&quot;  onmouseover=&quot;window.status=&#039;http://metabang.com/unclogit&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://metabang.com/unclogit&quot;&gt;Gary King&lt;/a&gt; discusses some &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=247&amp;amp;entry_id=77&quot;  onmouseover=&quot;window.status=&#039;http://metabang.com/unclogit/?p=150&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://metabang.com/unclogit/?p=150&quot;&gt;issues of XSLT&lt;/a&gt;. He concludes:&lt;br /&gt;
&lt;br /&gt;
&lt;blockquote&gt;I still feel as if there is less here than meets the eye; that it ought to be possible to express these graph-transformations more elegantly and with less fuss and bother.&lt;/blockquote&gt;&lt;br /&gt;
&lt;br /&gt;
To me, the only interesting part of XSLT isn&#039;t XSLT itself, it&#039;s the embedded XPath where XSLT&#039;s power comes from. XPath is a pair of scissors for cutting out the nodes of an XML document instance you&#039;re interested in and is about as powerful (and hence horrible to get right) as regular expressions  (although it&#039;s something completely different, of course). XSLT is just the framework which provides a relatively boring set of instructions and control-flow operations. And it&#039;s &quot;clean functional&quot; design only gets in the way every so often. Sure, coming from a Prolog and Lisp background, I know all the tricks to work around the hassle, but quite often it would be way easier to just set that damned variable *again*. If I want to do clean functional programming, I know where I can find a language without that XML syntax, thanks. Give me the unclean intermix of programming styles offered by Common Lisp anyday, please.&lt;br /&gt;
&lt;br /&gt;
Being a Lisp guy just like Gary, I would be happy to use &lt;quote&gt;a language with parenthesis&lt;/quote&gt;, as I have to do XML transformations quite often and the intermix of elements from different namespaces (XSLT namespace and target namespace) is mostly a pain to read and write. Using &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=248&amp;amp;entry_id=77&quot;  onmouseover=&quot;window.status=&#039;http://sourceforge.net/projects/xslide/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://sourceforge.net/projects/xslide/&quot;&gt;xslide&lt;/a&gt;, an Emacs mode for XSLT, eases the pain a considerable bit, but it still isn&#039;t really fun. And sometimes I need to hack XSLT in a proprietary system which only provides editor capabilities that know nothing about XML (think notepad-style editing capabilities) and then XSLT suddenly has the next most horrible syntax imaginable. However, the corporate world has its own rules and to be fair, the major benefit of XSLT is that you have one standard &lt;i&gt;syntax&lt;/i&gt; for XML transformations rather than having xyz numbers of incompatible library APIs.  &lt;br /&gt;
&lt;br /&gt;
Update: Also in response to Gary, David Lichteblau pointed out his approach to &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=249&amp;amp;entry_id=77&quot;  onmouseover=&quot;window.status=&#039;http://lichteblau.blogspot.com/2007/07/macros-for-xslt.html&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://lichteblau.blogspot.com/2007/07/macros-for-xslt.html&quot;&gt;(macro-)pre-processing XSLT stylesheets&lt;/a&gt; to overcome some of Gary&#039;s problems. 
    </content:encoded>

    <pubDate>Thu, 26 Jul 2007 08:54:10 +0200</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/77-guid.html</guid>
    
</item>
<item>
    <title>Explicit resource handling in Lisp</title>
    <link>http://hillview.bugwriter.net/archives/73-Explicit-resource-handling-in-Lisp.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/73-Explicit-resource-handling-in-Lisp.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=73</wfw:comment>

    <slash:comments>0</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=73</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    Recently, there was a discussion about &quot;the rise of functional languages&quot; over on &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=294&amp;amp;entry_id=73&quot; title=&quot;http://lwn.net/&quot;  onmouseover=&quot;window.status=&#039;http://lwn.net/&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot; &gt;Linux weekly news&lt;/a&gt;, in which one of the participant claimed that one of the major reasons why nobody uses functional languages in industrial settings would be the lack of explicit resource handling (where a resource is some supposedly &quot;alien&quot; object in the system, say a database handle or something like that).  What he was referring to was the inability to run code on allocating/deallocating a piece of resource. Of course, some people pointed him to various solutions, in particular I recurred to the usual WITH-* style-macros in which one would nest the access to the data while at the same time hiding all what one would do on allocation/de-allocation. His reply went something along the lines that such objects may need to be long-lived (thus a WITH-macro is inappropriate) and that the only resort would be the garbage collector and that there simply is no way of running code at a guaranteed (de-allocation) time. I have to admit that I have no idea how I could code around that problem in Common Lisp (garbage collection even isn&#039;t a defined term in the ANSI specification of CL, and I&#039;m very sure I haven&#039;t seen any mention of allocation/deallocation in it). &lt;br /&gt;
&lt;br /&gt;
Now, some months later, there is a discussion in comp.lang.lisp on the topic of &quot;portable finalizers&quot; and Rainer Joswig pointed to this &lt;a href=&quot;http://hillview.bugwriter.net/exit.php?url_id=295&amp;amp;entry_id=73&quot;  onmouseover=&quot;window.status=&#039;http://common-lisp.net/project/bknr/static/lmman/resour.xml&#039;;return true;&quot; onmouseout=&quot;window.status=&#039;&#039;;return true;&quot;  title=&quot;http://common-lisp.net/project/bknr/static/lmman/resour.xml&quot;&gt;chapter in the Lisp machine manual&lt;/a&gt; which talks about explicit resource handling the lisp machine. From the excerpt, I can&#039;t judge whether resources are first-class CLOS objects and hence the functions to handle them are generic functions, but if so that would actually allow running code on deallocating a resource, of course with the price of having to handle allocation/deallocation manually. I really wonder if any of todays CL implementations offers the same or at least similar functionality? 
    </content:encoded>

    <pubDate>Wed, 04 Jul 2007 14:48:53 +0200</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/73-guid.html</guid>
    
</item>
<item>
    <title>Fun with loop</title>
    <link>http://hillview.bugwriter.net/archives/72-Fun-with-loop.html</link>
            <category>Lisp</category>
    
    <comments>http://hillview.bugwriter.net/archives/72-Fun-with-loop.html#comments</comments>
    <wfw:comment>http://hillview.bugwriter.net/wfwcomment.php?cid=72</wfw:comment>

    <slash:comments>1</slash:comments>
    <wfw:commentRss>http://hillview.bugwriter.net/rss.php?version=2.0&amp;type=comments&amp;cid=72</wfw:commentRss>
    

    <author>nospam@example.com (Holger Schauer)</author>
    <content:encoded>
    Using Common Lisp, I want to split a list into two parts, in which the first resulting part has a fixed size (say 20 elements) and the rest, well, contains the rest of the list. This should also work when the list is actually shorter than the limit, which means I can&#039;t use subseq. The typically approach I would have chosen would involve the two traditional functions for doing something iteratively in CL, i.e. do, dotimes or dolist. However, this is ugly, and for the sake of learning something new, I had a look at how to solve the problem with loop.&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;&lt;a href=&quot;http://hillview.bugwriter.net/archives/72-Fun-with-loop.html#extended&quot;&gt;Continue reading &quot;Fun with loop&quot;&lt;/a&gt;
    </content:encoded>

    <pubDate>Thu, 28 Jun 2007 18:08:32 +0200</pubDate>
    <guid isPermaLink="false">http://hillview.bugwriter.net/archives/72-guid.html</guid>
    
</item>

</channel>
</rss>