summaryrefslogtreecommitdiff
path: root/py
diff options
context:
space:
mode:
Diffstat (limited to 'py')
-rw-r--r--py/mpconfig.h5
-rw-r--r--py/obj.h1
-rw-r--r--py/objexcept.c4
3 files changed, 1 insertions, 9 deletions
diff --git a/py/mpconfig.h b/py/mpconfig.h
index d96687b81..c2352bbdd 100644
--- a/py/mpconfig.h
+++ b/py/mpconfig.h
@@ -959,11 +959,6 @@ typedef double mp_float_t;
#define MICROPY_PY_BUILTINS_ROUND_INT (0)
#endif
-// Whether to support timeout exceptions (like socket.timeout)
-#ifndef MICROPY_PY_BUILTINS_TIMEOUTERROR
-#define MICROPY_PY_BUILTINS_TIMEOUTERROR (0)
-#endif
-
// Whether to support complete set of special methods for user
// classes, or only the most used ones. "Inplace" methods are
// controlled by MICROPY_PY_ALL_INPLACE_SPECIAL_METHODS below.
diff --git a/py/obj.h b/py/obj.h
index 969f3033b..b282c63db 100644
--- a/py/obj.h
+++ b/py/obj.h
@@ -650,7 +650,6 @@ extern const mp_obj_type_t mp_type_MemoryError;
extern const mp_obj_type_t mp_type_NameError;
extern const mp_obj_type_t mp_type_NotImplementedError;
extern const mp_obj_type_t mp_type_OSError;
-extern const mp_obj_type_t mp_type_TimeoutError;
extern const mp_obj_type_t mp_type_OverflowError;
extern const mp_obj_type_t mp_type_RuntimeError;
extern const mp_obj_type_t mp_type_StopAsyncIteration;
diff --git a/py/objexcept.c b/py/objexcept.c
index 594c4c650..59a0557b1 100644
--- a/py/objexcept.c
+++ b/py/objexcept.c
@@ -303,9 +303,6 @@ MP_DEFINE_EXCEPTION(Exception, BaseException)
MP_DEFINE_EXCEPTION(UnboundLocalError, NameError)
*/
MP_DEFINE_EXCEPTION(OSError, Exception)
-#if MICROPY_PY_BUILTINS_TIMEOUTERROR
- MP_DEFINE_EXCEPTION(TimeoutError, OSError)
-#endif
/*
MP_DEFINE_EXCEPTION(BlockingIOError, OSError)
MP_DEFINE_EXCEPTION(ChildProcessError, OSError)
@@ -319,6 +316,7 @@ MP_DEFINE_EXCEPTION(Exception, BaseException)
MP_DEFINE_EXCEPTION(NotADirectoryError, OSError)
MP_DEFINE_EXCEPTION(PermissionError, OSError)
MP_DEFINE_EXCEPTION(ProcessLookupError, OSError)
+ MP_DEFINE_EXCEPTION(TimeoutError, OSError)
MP_DEFINE_EXCEPTION(FileExistsError, OSError)
MP_DEFINE_EXCEPTION(FileNotFoundError, OSError)
MP_DEFINE_EXCEPTION(ReferenceError, Exception)