Improve typing syntax and type NamedTuples (#1610)

* Change to PEP 526 typing syntax

* Change from collections.namedtuple to typing.NamedTuple
This commit is contained in:
MiguelX413
2022-07-04 18:00:07 +00:00
committed by GitHub
parent 9b928b4679
commit 0c21da8c18
6 changed files with 66 additions and 35 deletions

View File

@@ -30,7 +30,7 @@ Iterator :class:`NodeIterator` and a context manager
It can be serialized and deserialized with :func:`save_structure_to_file`
and :func:`load_structure_from_file`, as well as with :mod:`json` and
:mod:`pickle` thanks to being a :func:`~collections.namedtuple`.
:mod:`pickle` thanks to being a :class:`~typing.NamedTuple`.
``resumable_iteration``
"""""""""""""""""""""""