[PATCH 6 of 7 v6] rebase: move local variables 'contf', 'abortf' and 'destspace' to the RR

Kostia Balytskyi ikostia at fb.com
Thu Jun 16 11:45:25 EDT 2016


My goal is to move most of the current logic of rebase to the RR class. This will achieve a couple of goals:

- reduce the amount of existing (v1, v2, v3, v4 …, v100) = function(u1, u2, … u100) since every variable is accessible via a self container

- allow further breakdown of logic into functionally independent components without introducing more (…) = func(…) things

- (in future) possible abstraction of some components of rebase from the others (I don’t have particular examples here)



In order to move to this state of rebase code, I am trying to move to the class as much things as possible. If we want to separate command-related logic from actual-rebase logic, we can always do it later. So I think that even ‘abort’ and ‘continue’ should be moved to the RR class.



On 6/16/16, 3:58 PM, "Yuya Nishihara" <youjah at gmail.com on behalf of yuya at tcha.org> wrote:



>On Mon, 13 Jun 2016 23:03:51 +0100, Kostia Balytskyi wrote:

>> # HG changeset patch

>> # User Kostia Balytskyi <ikostia at fb.com>

>> # Date 1465854334 -3600

>> #      Mon Jun 13 22:45:34 2016 +0100

>> # Node ID 0387ce5764968036c615b38f575e45fc9c0ae71d

>> # Parent  ad8e1710d3337924368905bdb1601c0bbc150e15

>> rebase: move local variables 'contf', 'abortf' and 'destspace' to the RR

>>

>> The variables this commit touches are command line options of the rebase

>> operation. Two of them ('contf' and 'abortf') are responsible for 'abort'

>> and 'continue' phases of rebase lifecycle, while 'destspace' is used to

>> search for default rebase destination. Commit moves these variables to

>> the previously introduced rebaseruntime class.

>

>'abort' and 'continue' sound like entry points to the RR. Do I miss the

>point of the RR class?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mercurial-scm.org/pipermail/mercurial-devel/attachments/20160616/f17ddbe5/attachment.html>


More information about the Mercurial-devel mailing list