Modifying MethodContext?

Stephen Pair spair at advantive.com
Tue Jul 24 05:07:55 UTC 2001


I need to add an instance variable to MethodContext.  What is the best
approach to doing so?  

- the VM relies on variables being at specific offsets
- MethodContext is a special object
- there are small and large contexts (would the size of these need to
change?)

So, I was thinking that I would need to take a stepped approach by
defining a subclass of MethodContext (with the added variable), add it
to the special objects, and have the VM use this class if available and
the regular MethodContext if not (perhaps for compatibility, I would
keep support for both).  Does this sound viable?  I seem to remember a
similar approach discussed when migrating object formats...

Thanks,
Stephen





More information about the Squeak-dev mailing list