diff --git a/pygtrie.py b/pygtrie.py index 0c41e05..1a357b0 100644 --- a/pygtrie.py +++ b/pygtrie.py @@ -39,7 +39,10 @@ __copyright__ = 'Copyright 2014 Google Inc.' -import collections as _collections +try: + import collections.abc as _collections +except ImportError: + import collections as _collections # Python 2.x and 3.x compatibility stuff if hasattr(dict, 'iteritems'):