On Fri, Aug 15, 2008 at 7:20 AM, Colin Putney <cputney@wiresong.ca> wrote:

On 14-Aug-08, at 6:57 PM, Eliot Miranda wrote:

Does a ChangeSetSlice record the preamble and postscript?  Do these get run automaticaly when a ChangeSetSlice is loaded?

No, that doesn't really fit with MC's versioning model.

Does your closure bootstrap have preamble and postscript? What do they do?

There are a few.  Preamble is essentially commentary so we can ignore it, but it would be great if MC2 supported a per-package or per-slice comment that allowed one to document the purpose, api and authorship et al of a package/slice.

Postscripts do the following:

compiler preload.cs
- rename MethodContext's receiverMap inst var to closureOrNil via
        MethodContext instVarNames at: 2 put: 'closureOrNil'
MethodContext can't be recompiled without brining the system down (infinite loop enumerating contexts for one).

Closure Compiler.cs:
- remove unused CompiledMethod class vars.  CompiledMethod can't reliably be recompiled because the ClassBuilder restricts it.
- run Smalltalk recreateSpecialObjectsArray to add BlockClosure to the array

Compile Using Closures.cs
- recompiles the system (could be done elsewhere in the bootstrap script, but its the kind of thing one needs to do after loading a slice/package that modifies the compiler)

Married Context Management Access.cs
- recompiles ContextPart and subclasses after changing the way inst var access is compiled (use long-form bytecodes instead of short-form, a hack used by the stack vm)

MultiPaneBrowser.cs
- toggles a preference enabling multi-pane browsing once entire change set has loaded

So recompilation, running low-level system inits, setting preferences, getting around limitations in the class builder.

HTH





Colin