Change in vdsm[master]: mount: Better and simpler __hash__

nsoffer at redhat.com nsoffer at redhat.com
Tue Jul 28 23:53:36 UTC 2015


Nir Soffer has posted comments on this change.

Change subject: mount: Better and simpler __hash__
......................................................................


Patch Set 4:

(1 comment)

https://gerrit.ovirt.org/#/c/43978/4//COMMIT_MSG
Commit Message:

Line 6: 
Line 7: mount: Better and simpler __hash__
Line 8: 
Line 9: Mixing type(self) in a hash is not a good idea, all instance of old
Line 10: style class have the same type. It is better to use the __class__
> but Mount is a new-style class, it does not really matter.
Using __class__ works for both old and new style classes, so it is a more portable pattern. Sure, for this class it does not matter.
Line 11: attribute to get the hash of the class.
Line 12: 
Line 13: The hash values were mixed in a poor way. There is no need to implement
Line 14: when we can use the hash function of the tuple object, which does a


-- 
To view, visit https://gerrit.ovirt.org/43978
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I6030c441c7137d65f4038d86e9813719429250c0
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: Adam Litke <alitke at redhat.com>
Gerrit-Reviewer: Ala Hino <ahino at redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini at redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Freddy Rolland <frolland at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Nir Soffer <nsoffer at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list