Commit a881695f authored by Martin Reinecke's avatar Martin Reinecke

small performance tweaks

parent 5661787e
Pipeline #31954 passed with stages
in 4 minutes
......@@ -90,6 +90,8 @@ class MultiDomain(frozendict):
if self is x:
return True
x = MultiDomain.make(x)
if self is x:
return True
if (self, x) in MultiDomain._compatCache:
return True
commonKeys = set(self.keys()) & set(x.keys())
......@@ -104,10 +106,11 @@ class MultiDomain(frozendict):
if self is x:
return True
x = MultiDomain.make(x)
if (self, x) in MultiDomain._subsetCache:
if self is x:
return True
if len(x) == 0:
MultiDomain._subsetCache.add((self, x))
return True
if (self, x) in MultiDomain._subsetCache:
return True
for key in self.keys():
if key not in x:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment