diff options
author | Sebastian Berg <sebastian@sipsolutions.net> | 2022-05-27 15:10:59 -0700 |
---|---|---|
committer | Sebastian Berg <sebastian@sipsolutions.net> | 2022-06-15 11:42:02 -0700 |
commit | c855cecce28d5f925c5b2e015a0bdfd1aa472590 (patch) | |
tree | 35b7e271aee7b3d5df416ecea5e3bd55f4d1ecbb /numpy/core/multiarray.py | |
parent | 09d407a3cd24b712f8a40748262e00188e8b8efa (diff) | |
download | numpy-c855cecce28d5f925c5b2e015a0bdfd1aa472590.tar.gz |
API: Expose `get_promotion_state` and `set_promotion_state`
We need to be able to query the state for testing, probably should
be renamed before the end, but need to have something for now.
Diffstat (limited to 'numpy/core/multiarray.py')
-rw-r--r-- | numpy/core/multiarray.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/numpy/core/multiarray.py b/numpy/core/multiarray.py index 8c14583e6..e8ac27987 100644 --- a/numpy/core/multiarray.py +++ b/numpy/core/multiarray.py @@ -40,7 +40,8 @@ __all__ = [ 'ravel_multi_index', 'result_type', 'scalar', 'set_datetimeparse_function', 'set_legacy_print_mode', 'set_numeric_ops', 'set_string_function', 'set_typeDict', 'shares_memory', 'tracemalloc_domain', 'typeinfo', - 'unpackbits', 'unravel_index', 'vdot', 'where', 'zeros'] + 'unpackbits', 'unravel_index', 'vdot', 'where', 'zeros', + 'get_promotion_state', 'set_promotion_state'] # For backward compatibility, make sure pickle imports these functions from here _reconstruct.__module__ = 'numpy.core.multiarray' @@ -68,6 +69,8 @@ promote_types.__module__ = 'numpy' set_numeric_ops.__module__ = 'numpy' seterrobj.__module__ = 'numpy' zeros.__module__ = 'numpy' +get_promotion_state.__module__ = 'numpy' +set_promotion_state.__module__ = 'numpy' # We can't verify dispatcher signatures because NumPy's C functions don't |