Patchwork D2966: context: remove unwanted assignments in basectx.__new__() (API)

login
register
mail settings
Submitter phabricator
Date March 30, 2018, 5:24 p.m.
Message ID <cdfd2fdc9e2b3e842cbb0795e4567edc@localhost.localdomain>
Download mbox | patch
Permalink /patch/29968/
State Not Applicable
Headers show

Comments

phabricator - March 30, 2018, 5:24 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGd7f3fdab94c4: context: remove unwanted assignments in basectx.__new__() (API) (authored by martinvonz, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D2966?vs=7368&id=7389

REVISION DETAIL
  https://phab.mercurial-scm.org/D2966

AFFECTED FILES
  mercurial/context.py

CHANGE DETAILS




To: martinvonz, #hg-reviewers, indygreg
Cc: mercurial-devel

Patch

diff --git a/mercurial/context.py b/mercurial/context.py
--- a/mercurial/context.py
+++ b/mercurial/context.py
@@ -66,13 +66,7 @@ 
         if isinstance(changeid, basectx):
             return changeid
 
-        o = super(basectx, cls).__new__(cls)
-
-        o._repo = repo
-        o._rev = nullrev
-        o._node = nullid
-
-        return o
+        return super(basectx, cls).__new__(cls)
 
     def __bytes__(self):
         return short(self.node())