aboutsummaryrefslogtreecommitdiff
path: root/pyasn1/type
diff options
context:
space:
mode:
authorIlya Etingof <etingof@gmail.com>2017-08-21 23:14:42 +0200
committerIlya Etingof <etingof@gmail.com>2017-08-21 23:14:42 +0200
commit368b1d2f3e649d39239a827e7123e517acf35c24 (patch)
treef9030d6a27a522ce9ac77735ff9adfb2b22ce008 /pyasn1/type
parent2f01eda8c4cca506aff03088def042c6f482b613 (diff)
downloadpyasn1-368b1d2f3e649d39239a827e7123e517acf35c24.tar.gz
fix to TagSet hash value build
Diffstat (limited to 'pyasn1/type')
-rw-r--r--pyasn1/type/tag.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/pyasn1/type/tag.py b/pyasn1/type/tag.py
index df305a1..6c0e2c1 100644
--- a/pyasn1/type/tag.py
+++ b/pyasn1/type/tag.py
@@ -172,11 +172,11 @@ class TagSet(object):
def __init__(self, baseTag=(), *superTags):
self.__baseTag = baseTag
self.__superTags = superTags
- self.__superTagsSignature = tuple(
+ self.__superTagsClassId = tuple(
[(superTag.tagClass, superTag.tagId) for superTag in superTags]
)
self.__lenOfSuperTags = len(superTags)
- self.__hash = hash(self.__superTags)
+ self.__hash = hash(self.__superTagsClassId)
def __str__(self):
return self.__superTags and '+'.join([str(x) for x in self.__superTags]) or '[untagged]'
@@ -199,22 +199,22 @@ class TagSet(object):
return self.__superTags[i]
def __eq__(self, other):
- return self.__superTagsSignature == other
+ return self.__superTagsClassId == other
def __ne__(self, other):
- return self.__superTagsSignature != other
+ return self.__superTagsClassId != other
def __lt__(self, other):
- return self.__superTagsSignature < other
+ return self.__superTagsClassId < other
def __le__(self, other):
- return self.__superTagsSignature <= other
+ return self.__superTagsClassId <= other
def __gt__(self, other):
- return self.__superTagsSignature > other
+ return self.__superTagsClassId > other
def __ge__(self, other):
- return self.__superTagsSignature >= other
+ return self.__superTagsClassId >= other
def __hash__(self):
return self.__hash