opening it up with Common Lisp

Favorite weblogs

Lisp Related

Bill Clementson

Finding Lisp


Planet Lisp



Talking Points Memo

This Modern World

Working for Change

Other home


Recent Readings

Book review: Darwinia
Reviewed: Friday, August 11, 2006

Summer reading: Spin
Reviewed: Saturday, August 5, 2006

Reviewed: Tuesday, July 18, 2006

the Omnivoire's Delimma
Reviewed: Wednesday, July 12, 2006

the Golem's Eye
Reviewed: Wednesday, May 31, 2006


Where did I go?
Sunday, September 24, 2006

Blogging fell through the gaping cracks between work obligations, home obligations, a crashed hard drive, travel and other minor insanities, Some of those have now leveled (home and work), been partially ameliorated (crashed hard drive) or completed (travel). Others (minor insanities) are just the things we have to live with .

I've only had two casualities from my hard drive collapse: my GPG key and my blogging setup. The first is being regenerated even as I type; the second is a bit of a bother. I've been using Tinderbox and am relatively happy with it (though it has it's peculularities that sometimes drive Zach Beane over at Planet Lisp rather mad (sorry Zach)). Now, however, I've lost my registration information (and it was really from my previous job) and I don't use Tinderbox enough to want to buy it again. I could get with the program and just use one of the existing blog engines but... I could use CL-Blog or blitzblog but... I could write my own but...

Anyhow. My new key is over at and several software updates (all minor) are in the works.

Keep peace.

RDF Triples in XML
Sunday, August 20, 2006

(After all, where else would you put them?).

Even after everything is in RDF, you still need to find someplace to put it and a way to write it down. Big disks answers the first question but the second has turned out to be surprisingly hard. Since XML has become the one (markup language) to rule them all, it was no surprise that people turned to it for the answers. Unfortunately, dealing with everything has a way of pulling in competing constituencies and those pesky subgroups tend to pull things into a muddle. This left RDF/XML of several diverse forms each very successful but each with its own problems. This paper presents another way to look at stuff that, as far as I know, has gone on to become quite successful.

IT Conversations
Sunday, August 20, 2006

  • Tara Lemmey talks about US security in the age of "terror". If these ideas are actually implemented, then things might become better. My guess, however, is that we'll just have more technology without thought scares.
  • Ray Lane talks about software and stuff stream of consciousness style at Software 2006. His stream is moderately interesting.
  • Elias Torres talks about the Semantic Web (RDF, OIL, SPARQL, oh my!) with Phil Windley. Torres does a good job explaining why we care though I can't help but hear shades of the "AI will solve everything" from the early 80's whenever I hear about the Semantic Web.

more "real" C++ macros via template metaprogramming
Saturday, August 19, 2006

If it didn't end up being so ugly, it would be cute.

Although this technique might seem like just a cute C++ trick, it becomes powerful when combined with normal C++ code. In this hybrid approach, source code contains two programs: the normal C++ run-time program, and a template metaprogram which runs at compile time. Template metaprograms can generate useful code when interpreted by the compiler, such as a massively inlined algorithm -- that is, an implementation of an algorithm which works for a specific input size, and has its loops unrolled. This results in large speed increases for many applications.

This is from a longer article by Todd Veldhuizen referenced by Scott Meyers (it's on the web somewhere but I seem to have misplaced it ).

Someone should create a language that lets you do this without having to jump through so many hoops. It could work per taking source code as inputs and writing out new source code with the whole power of the language behind the transformations. A language like that would blow C++ out of the water in terms of popularity. What's that. Oh, sorry. I went off my meds again.

SPAM on the lam? Not for me!
Saturday, August 19, 2006

It used to be that most of my SPAM went into junk. Lately, however, a great deal of stuff that looks as if it should be easy to categorize is ending up in my inbox. Grrrr.

I'm guessing that I should try retraining my SPAM filter (in OS X's Apple Mail) or switch to something like Michael's Tsai's SpamSieve. I used SpamSieve once before and liked it -- but why pay when Apple Mail seemed to be doing as good (or at least nearly as good) of a job? Is anyone else experiencing this?

Feedback: good and bad
Friday, August 18, 2006

It's ironic I received both high praise and an indictment for my Lisp software on the same day! Both, however, were deserved. Well, I know I deserve the indictment and I'm pretty sure that the praise is justified too. First, I heard that CL-Markdown's new extensions mechanism

I was able to complete a project today, just in time, and leave for seven days of vacation tomorrow. This wouldn't have been possible in that form without markdown extensions...

That cheered me up. Later in the day, however, I heard that:

... most of the web pages for your various lisp packages need to be updated. You don't list nearly all of the required dependencies. ... I'm so annoyed from having to go through the discovery process that I'll let you discover which pages are inadequate.

Which is quite true. I suppose it would be sort of OK if I didn't list any dependencies but only listing some of them really opens the door for frustration. Besides, it's easy to pull all of this stuff and include it in the web pages automatically.

Things to do:

  • Switch from lml2 to CL-Markdown for my web site
  • Add CL-Markdown extensions to include the dependencies automatically
  • Improve the Enterprise Lisp system pages so that they list this stuff automatically too
  • Keep on keeping on.

Thanks for both the kind words and the less kind ones. I want Lisp to succeed and that's only going to happen if the barriers to entry become ever lower.

Friday, August 18, 2006

I just heard about RIFE which sounds like RAILS only it's Java, etc... The nice thing is that Lispers could start working on LIFE which has gotta be good, right? The linked interview has an interesting comment differentiating Rails from RIFE:

Some people criticize RIFE for not being like Ruby on Rails, where you can just start coding and have something up and running.


Why? Because we've been bitten so many times by the maintainability issue. We think that declaring certain things beforehand makes your application easier to maintain—for instance, it forces you to think of how state is being managed in your application.

Update: CL-Markdown again
Monday, August 14, 2006

Thanks for Frank Schorr for noticing that CL-Markdown sometimes failed to produce output. Actually if it failed once, it never stopped failing but when it succeeded, it never failed. It was a file compilation order dependency problem that didn't occur in my usual development environment. I'd been thinking that having a system compile an ASDF system in every order allowed by the dependencies would be a good way to catch certain bugs... it would have caught this one (assuming that a lot of additional infrastructure was in place <smile>).

When, on when, will someone kick me in the butt so that I can get back to Enterprise Lisp? New files are up on

the Human Condition
Sunday, August 13, 2006

I like conditions. I like them a lot. I like to use them to describe bad program states instead of strings. (e.g., (assert (ok-p state) nil 'it-is-not-ok-condition :state state) instead of (assert (ok-p state) nil "It is not ok")). I like them because you can easily test whether or not they happened programmatically and because using them helps to centralize error messages -- and thus gives me hope that I can make them consistent. There is a catch though: define-condition is a prolix form. Thus Metatilities has long had defcondition to make writing them a bit easier and yesterday I wrote a sibling macro (with the same name) to handle my most common case. The macro is simplicity itself:

(defmacro defcondition (name (&rest super-conditions) 
			slot-specs format &body args)
  (flet ((massage-slot (slot-spec)
	   (cond ((atom slot-spec)
		    :initarg ,(read-from-string (format nil ":~a" slot-spec))))
	 (massage-format-arg (arg)
	   (cond ((atom arg)
		  `(slot-value condition ',arg)) 
       (export '(,name))
       (define-condition ,name ,super-conditions
	 ,(mapcar #'massage-slot slot-specs)
	 (:report (lambda (condition stream)
		    (format stream ,format 
			    ,@(mapcar #'massage-format-arg args))))))))

and this lets us write

(define-condition record-number-too-large-error
  ((record-count :initarg :record-count))
   (lambda (condition stream)
     (format stream 
	     "Record number ~a is too large for this store. Store size is ~a."
	     (slot-value condition 'record-number)
	     (slot-value condition 'record-count)))))


(defcondition record-number-too-large-error
    "Record number ~a is too large for this store. Store size is ~a."
  record-number record-count)

(the record-number slot is inherited). It's not much but its enough to make writing simple condition like this almost as easy as writing an error message as string. Programming environments are (in part) about reducing impedance and about making it easy to do the right thing.

Book review: Darwinia
Friday, August 11, 2006

I very much enjoyed Robert Charles Wilson's Spin and I was looking forward to reading Darwinia. I'm glad I read them in the order I did because I thought Spin was superb and Darwinia both trite and silly. The characters are well drawn and relationships matter but the central premise -- that earth (and the rest of the universe) is essentially a library book come to life and is rewriting itself because of the attack of computer viruses on steroids; that everything we know is composed of a vast cosmological battle between sentience and these viruses... well, it's an interesting idea.

Darwinia feels as if it could have been great but it isn't. It feels tacked together from several weaker ideas and grand notions and never quite evolves beyond itself. Oh well, you can't always write a masterpiece.

Update: CL-Markdown
Tuesday, August 8, 2006

I've corrected another few bugs in CL-Markdown and improved the extensions a bit.

  • Fixed error in the processing of multiple bracketed things (e.g., [a][b] and [c][d]).
  • Improved table of contents processing.

It actually works pretty well (I suppose I shouldn't be surprised! Smile)

:explain that :box, will you?
Tuesday, August 8, 2006

One of Common Lisp's darker arts is optimizing functions. It's a beautiful idea: don't worry (too much) about performance until you've found the critical sections of your code; then tell the compiler what you'd like and, voila, faster code. Since compilers differ, however, and since you're never quite sure what incantation is going to convince Lisp to do "the right thing" (*), you're often left flipping declarations around like hot potatoes.

Enter Allegro Common Lisp, version 8.0 I've been working lately (for money even!) in ACL and one of the wonderful new features is that you can ask the compiler to tell you what it thinks and what it wants. I've wanted this ability for a long time (I even talked about it at ILC 200? in NYC). Let the programming environment notice that such and such a function is suboptimal and tell me that if I scratch it's back (with a little more information), then it can scratch mine (with a little more performance). ACL's explain feature isn't quite that, but it's a great step in that direction.

(*) I.e., what you want it to. Joke.

Cellular signposts
Tuesday, August 8, 2006

I suffer from psoriasis (and it's not just a heartbreak!). One of the many interesting questions about this disease is why this little bit of skin is undergoing massive immune mediated wonkiness (MIMW) and this bit of skin next to it thinks that everything is normal. This article (which I found via the American Scientist) gives part of an explanation. Cool.

Home | About | Quotes | Recent | Archives

Copyright -- Gary Warren King, 2004 - 2006