The perfect revision control system

Jason Johnson jason.johnson.081 at gmail.com
Fri Feb 15 21:06:00 UTC 2008


Hello all,

I am considering starting on a project idea I had for a darcs-like
version control system in Squeak (based on the low level Delta streams
classes), but I thought I would pull a little input first.  The main
thing I want to know is, what is the consensus on the scope of
changes?  Should it stop at method, or should it go all the way into
the source code?  Since everything, including the parsing, is done in
Smalltalk we can go down to the AST level for changes.

Stated another way, if you have a method:

SomeClass>>someMethod: value
      |i|
      i := value * 10

Later modified to:

SomeClass>>someMethod: value
      |i|
      i := value * 10
      Transcript show: i

Then if the change scope goes only to the method level then there is
no dependency between these two versions, the second one completely
replaces the first [1].  But if we model down to the AST then the
second version clearly depends on the first.

Using the AST, and since the system would be specialized for
Smalltalk, it can be much more advanced in tracking actual changes
then anything other revision system (since unlike a darcs that works
with anything, this system can know if new code uses variables added
earlier and so on), but my concern is that this might produce some
behaviors or conflicts that users don't expect.  Well that and it's
harder to implement to the AST level for me (since the Delta stream
classes don't store this level of information afaik).

[1] Well, the only dependency is the last one must be last, but if one
has 10 such changes the first 9 could be applied in any order or
completely ignored.  Of course this seems like an irrelevant issue for
a one man repository, but it becomes more important in the case of
merges from various distributed sources.



More information about the Squeak-dev mailing list