diff options
author | Daniel Silverstone <daniel.silverstone@codethink.co.uk> | 2019-02-06 13:45:23 +0000 |
---|---|---|
committer | Benjamin Schubert <ben.c.schubert@gmail.com> | 2019-02-06 17:30:13 +0000 |
commit | 335ef2b84e1c11e4b2186153bfed3347d46f69ec (patch) | |
tree | a7160ada4951442e2531e609d925c2682518b131 /buildstream | |
parent | 256bcde5e09848f62b3621c4db0e56440d293889 (diff) | |
download | buildstream-335ef2b84e1c11e4b2186153bfed3347d46f69ec.tar.gz |
loadelement.py: Switch from roaringbitmap to pyroaring
The licence for roaringbitmap was not compatible. pyroaring is
a similar project which is MIT licensed and is slightly better on
memory too.
Signed-off-by: Daniel Silverstone <daniel.silverstone@codethink.co.uk>
Diffstat (limited to 'buildstream')
-rw-r--r-- | buildstream/_loader/loadelement.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/buildstream/_loader/loadelement.py b/buildstream/_loader/loadelement.py index 465d97f2c..17154ee64 100644 --- a/buildstream/_loader/loadelement.py +++ b/buildstream/_loader/loadelement.py @@ -21,7 +21,7 @@ from collections.abc import Mapping from itertools import count -from roaringbitmap import RoaringBitmap, ImmutableRoaringBitmap # pylint: disable=no-name-in-module +from pyroaring import BitMap, FrozenBitMap # pylint: disable=no-name-in-module # BuildStream toplevel imports from .._exceptions import LoadError, LoadErrorReason @@ -123,7 +123,7 @@ class LoadElement(): if self._dep_cache: return - self._dep_cache = RoaringBitmap() + self._dep_cache = BitMap() for dep in self.dependencies: elt = dep.element @@ -137,7 +137,7 @@ class LoadElement(): # And we depend on everything this element depends on self._dep_cache.update(elt._dep_cache) - self._dep_cache = ImmutableRoaringBitmap(self._dep_cache) + self._dep_cache = FrozenBitMap(self._dep_cache) # _extract_depends_from_node(): |