From 81ac996deb0890f26cfd60bc62f9bd0827c4a9d1 Mon Sep 17 00:00:00 2001 From: Laurens Valk Date: Mon, 28 Nov 2022 13:45:48 +0100 Subject: [PATCH] ubuiltins: Fix next. MICROPY_PY_BUILTINS_NEXT2 is not enabled. --- src/ubuiltins/__init__.py | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/src/ubuiltins/__init__.py b/src/ubuiltins/__init__.py index ba6be83..b3362a4 100644 --- a/src/ubuiltins/__init__.py +++ b/src/ubuiltins/__init__.py @@ -746,21 +746,9 @@ def min(*args): """ -@overload def next(iterator: Iterator) -> Any: - ... - - -@overload -def next(iterator: Iterator, default: Any) -> Any: - ... - - -def next(*args): """ Retrieves the next item from the iterator by calling its ``__next__()`` method. - If ``default`` is given, it is returned if the iterator is exhausted, - otherwise ``StopIteration`` is raised. """