Image-based development in Lisp
Posted: Mon Jul 26, 2010 2:53 am
When programming in Smalltalk, one finds that the image is ubiquitous. Most Smalltalk programmers keep many different images around on their computer--- often for years---returning to work on an image whenever its suits them. Indeed, one usually starts up Smalltalk by selecting and dragging a particular image to the VM. The image is a vital part of Smalltalk, as it performs so many functions. When one queries for all instances of a class Foo
Smalltalk answers the query by scouring through its image for the appropriate objects.
On the web are some demos of how users can debug a running Smalltalk program such as a Solitaire game or a spaceship game, making some changes in the debugger, and seeing those changes reflected immediately in the live program. The interaction between the debugger and the running program depends heavily on the image. As such, Smalltalk would not be Smalltalk were it not for its image.
Now I would like to understand how extensively Lisp uses its image. From what I can tell, while a Lisp image provides a means of saving the run-time state of a Lisp environment so that users can save and load an image to resume work, it does not quite leverage the image in the same way that Smalltalk does, because the Lisp tools are quite different from Smalltalk tools.
For example, if I were to save a Smalltalk image and restart it a year later, I could quickly reconstruct the work I was doing because there are so many visual cues available when the image starts up. Usually a System Browser is present in the image, so I can see at a glance the packages that I have loaded into the image and the classes that I was working on. If a debugger is open, I can look at the last method I was examining, and try to retrace the problem I was trying to solve.
I've been using the LispWorks Personal Edition IDE, in which SAVE-IMAGE is not available, so I am not able to experiment with Lisp images (until I pay for a full license). Can I instead ask the experienced Lispers how they use the Lisp image when they program? Are they able to recall and retrace the state of their programming when they reload an old image? Are they able to explore and query a Lisp image for information such as the allInstances query above? Does the presence of an image in Lisp greatly enhance the ability to develop code in Lisp as much as it does in Smalltalk?
Code: Select all
Smalltalk allInstances select: [:each | each isKindOf: Foo]
On the web are some demos of how users can debug a running Smalltalk program such as a Solitaire game or a spaceship game, making some changes in the debugger, and seeing those changes reflected immediately in the live program. The interaction between the debugger and the running program depends heavily on the image. As such, Smalltalk would not be Smalltalk were it not for its image.
Now I would like to understand how extensively Lisp uses its image. From what I can tell, while a Lisp image provides a means of saving the run-time state of a Lisp environment so that users can save and load an image to resume work, it does not quite leverage the image in the same way that Smalltalk does, because the Lisp tools are quite different from Smalltalk tools.
For example, if I were to save a Smalltalk image and restart it a year later, I could quickly reconstruct the work I was doing because there are so many visual cues available when the image starts up. Usually a System Browser is present in the image, so I can see at a glance the packages that I have loaded into the image and the classes that I was working on. If a debugger is open, I can look at the last method I was examining, and try to retrace the problem I was trying to solve.
I've been using the LispWorks Personal Edition IDE, in which SAVE-IMAGE is not available, so I am not able to experiment with Lisp images (until I pay for a full license). Can I instead ask the experienced Lispers how they use the Lisp image when they program? Are they able to recall and retrace the state of their programming when they reload an old image? Are they able to explore and query a Lisp image for information such as the allInstances query above? Does the presence of an image in Lisp greatly enhance the ability to develop code in Lisp as much as it does in Smalltalk?