Imprinting or not

Chris Cunnington smalltalktelevision at gmail.com
Sun Sep 11 15:15:36 UTC 2011


I follow the instructions in the alpha's Wormhole server. I have an 
Other Browser that sees the contents of the micro image.

( Other, by the way, is the name of a class. Not the best of names, I 
don't think. So the name of the browser as "Other Browser" is being 
specific, because it is a browser that displays instances of Other. I 
think Other instances are proxies of the contents of the mini image. Of 
course, I may have this wrong. You can find a class in the alpha called 
"Other", so I leave you to see if you draw the same conclusion I did.)

I can see the classes in the mini image. I want to change one. I want to 
start hacking the mini image. How do I do that? I use the Other Browser 
the same way I would any browser: change the code; and, save. That's the 
method, I think, for "imprinting" the remote image.

I start small. I add a class comment to a class in the mini image. I 
save. I highlight the code in the Wormhole server to snapshot the mini 
image. I close everything down. Start everything up and see if the 
comment is there. It is not. I have not imprinted.

But is that because I used a class comment and not actual code?

You will read that Spoon makes a deal about the two kinds of content in 
a CompiledMethod: byte codes and literals. I finally looked up what a 
literal is. A literal can be a number, a character, a string, a symbol, 
or an array containing any of the previous four. Spoon, I think, when it 
puts the compiled methods in the mini image replaces the literals with 
"literal markers". Do the actual literals stay in the history image?

So, since my class comment is a string, and therefor a literal, perhaps 
it was not shipped to the mini image. You will notice that the mini 
image has no class comments whatsoever.

I don't think it went better with a piece of code. So making permanent 
changes to the mini/remote image is something I haven't figured out yet. 
I have yet to imprint.


Chris


More information about the Spoon mailing list