[PATCH] RevisionSpec can be instantiated from another RevisionSpec

John A Meinel john at arbash-meinel.com
Sat Sep 17 19:17:38 BST 2005


In several places in the code, something tries to lookup a RevisionSpec
from another RevisionSpec object. The attached patch makes it so that
this just returns a new object of the same type as the original.

It also adds an equality test for 2 RevisionSpec objects, and some tests
to make sure things work correctly. (It took me a while to realize that
the return value of __new__() is used to call the __init__ with the
original parameters, not the ones that you supply, so you have to have
both __new__ and __init__ handle the new case).

This patch can be found on my integration branch (revno 1216).

John
=:->
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: revision-spec-from-revspec.cset
Url: https://lists.ubuntu.com/archives/bazaar/attachments/20050917/b209b8b5/attachment.diff 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 253 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20050917/b209b8b5/attachment.pgp 


More information about the bazaar mailing list