Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-immutables for 
openSUSE:Factory checked in at 2022-08-08 08:44:56
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-immutables (Old)
 and      /work/SRC/openSUSE:Factory/.python-immutables.new.1521 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-immutables"

Mon Aug  8 08:44:56 2022 rev:9 rq:990245 version:0.18

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-immutables/python-immutables.changes      
2022-03-02 18:20:28.472654612 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-immutables.new.1521/python-immutables.changes
    2022-08-08 08:45:00.310419289 +0200
@@ -1,0 +2,8 @@
+Tue Jul 19 12:26:30 UTC 2022 - Dirk M??ller <dmuel...@suse.com>
+
+- update to 0.18:
+  * Fix iteration when tree is 7 levels deep and has collissions
+  * Test on python 3.10
+  * consolidate mypy and pytest config into pyproject.toml
+
+-------------------------------------------------------------------

Old:
----
  immutables-0.16.tar.gz

New:
----
  immutables-0.18.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-immutables.spec ++++++
--- /var/tmp/diff_new_pack.F3Zj2A/_old  2022-08-08 08:45:00.762420619 +0200
+++ /var/tmp/diff_new_pack.F3Zj2A/_new  2022-08-08 08:45:00.766420630 +0200
@@ -19,14 +19,14 @@
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 %define skip_python2 1
 Name:           python-immutables
-Version:        0.16
+Version:        0.18
 Release:        0
 Summary:        Immutable collections for Python
 License:        Apache-2.0
 URL:            https://github.com/MagicStack/immutables
 Source:         
https://files.pythonhosted.org/packages/source/i/immutables/immutables-%{version}.tar.gz
 BuildRequires:  %{python_module devel}
-BuildRequires:  %{python_module mypy}
+BuildRequires:  %{python_module mypy >= 0.942}
 BuildRequires:  %{python_module pytest}
 BuildRequires:  %{python_module setuptools}
 BuildRequires:  fdupes

++++++ immutables-0.16.tar.gz -> immutables-0.18.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/MANIFEST.in 
new/immutables-0.18/MANIFEST.in
--- old/immutables-0.16/MANIFEST.in     2021-08-07 21:41:10.000000000 +0200
+++ new/immutables-0.18/MANIFEST.in     2022-05-22 08:24:25.000000000 +0200
@@ -1,4 +1,4 @@
 recursive-include tests *.py
 recursive-include immutables *.py *.c *.h *.pyi
 include LICENSE* NOTICE README.rst bench.png
-include mypy.ini immutables/py.typed
+include immutables/py.typed
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/PKG-INFO new/immutables-0.18/PKG-INFO
--- old/immutables-0.16/PKG-INFO        2021-08-07 21:41:15.075528100 +0200
+++ new/immutables-0.18/PKG-INFO        2022-05-22 08:24:35.646268800 +0200
@@ -1,12 +1,11 @@
 Metadata-Version: 2.1
 Name: immutables
-Version: 0.16
+Version: 0.18
 Summary: Immutable Collections
 Home-page: https://github.com/MagicStack/immutables
 Author: MagicStack Inc
 Author-email: he...@magic.io
 License: Apache License, Version 2.0
-Platform: UNKNOWN
 Classifier: License :: OSI Approved :: Apache Software License
 Classifier: Intended Audience :: Developers
 Classifier: Programming Language :: Python :: 3 :: Only
@@ -148,5 +147,3 @@
 -------
 
 Apache 2.0
-
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/immutables/_map.h 
new/immutables-0.18/immutables/_map.h
--- old/immutables-0.16/immutables/_map.h       2021-08-07 21:41:10.000000000 
+0200
+++ new/immutables-0.18/immutables/_map.h       2022-05-22 08:24:25.000000000 
+0200
@@ -4,7 +4,7 @@
 #include <stdint.h>
 #include "Python.h"
 
-#define _Py_HAMT_MAX_TREE_DEPTH 7
+#define _Py_HAMT_MAX_TREE_DEPTH 8
 
 
 #define Map_Check(o) (Py_TYPE(o) == &_Map_Type)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/immutables/_version.py 
new/immutables-0.18/immutables/_version.py
--- old/immutables-0.16/immutables/_version.py  2021-08-07 21:41:10.000000000 
+0200
+++ new/immutables-0.18/immutables/_version.py  2022-05-22 08:24:25.000000000 
+0200
@@ -10,4 +10,4 @@
 # supported platforms, publish the packages on PyPI, merge the PR
 # to the target branch, create a Git tag pointing to the commit.
 
-__version__ = '0.16'
+__version__ = '0.18'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/immutables/pythoncapi_compat.h 
new/immutables-0.18/immutables/pythoncapi_compat.h
--- old/immutables-0.16/immutables/pythoncapi_compat.h  2021-08-07 
21:41:10.000000000 +0200
+++ new/immutables-0.18/immutables/pythoncapi_compat.h  2022-05-22 
08:24:25.000000000 +0200
@@ -1,35 +1,15 @@
-// Header file providing new functions of the Python C API to old Python
-// versions.
-//
-// File distributed under the MIT license.
+// Header file providing new C API functions to old Python versions.
 //
+// File distributed under the Zero Clause BSD (0BSD) license.
 // Copyright Contributors to the pythoncapi_compat project.
 //
-// Permission is hereby granted, free of charge, to any person obtaining a copy
-// of this software and associated documentation files (the "Software"), to 
deal
-// in the Software without restriction, including without limitation the rights
-// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-// copies of the Software, and to permit persons to whom the Software is
-// furnished to do so, subject to the following conditions:
-//
-// The above copyright notice and this permission notice shall be included in 
all
-// copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 
FROM,
-// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 
THE
-// SOFTWARE.
-//
 // Homepage:
-// https://github.com/pythoncapi/pythoncapi_compat
+// https://github.com/python/pythoncapi_compat
 //
 // Latest version:
-// 
https://raw.githubusercontent.com/pythoncapi/pythoncapi_compat/master/pythoncapi_compat.h
+// 
https://raw.githubusercontent.com/python/pythoncapi_compat/master/pythoncapi_compat.h
 //
-// SPDX-License-Identifier: MIT
+// SPDX-License-Identifier: 0BSD
 
 #ifndef PYTHONCAPI_COMPAT
 #define PYTHONCAPI_COMPAT
@@ -46,24 +26,34 @@
 // the inline keyword in C (only in C++): use __inline instead.
 #if (defined(_MSC_VER) && _MSC_VER < 1900 \
      && !defined(__cplusplus) && !defined(inline))
-#  define inline __inline
-#  define PYTHONCAPI_COMPAT_MSC_INLINE
-   // These two macros are undefined at the end of this file
+#  define PYCAPI_COMPAT_INLINE(TYPE static __inline TYPE
+#else
+#  define PYCAPI_COMPAT_STATIC_INLINE(TYPE) static inline TYPE
 #endif
 
 
+// C++ compatibility
+#ifdef __cplusplus
+#  define PYCAPI_COMPAT_CAST(TYPE, EXPR) reinterpret_cast<TYPE>(EXPR)
+#  define PYCAPI_COMPAT_NULL nullptr
+#else
+#  define PYCAPI_COMPAT_CAST(TYPE, EXPR) ((TYPE)(EXPR))
+#  define PYCAPI_COMPAT_NULL NULL
+#endif
+
 // Cast argument to PyObject* type.
 #ifndef _PyObject_CAST
-#  define _PyObject_CAST(op) ((PyObject*)(op))
+#  define _PyObject_CAST(op) PYCAPI_COMPAT_CAST(PyObject*, op)
 #endif
 #ifndef _PyObject_CAST_CONST
-#  define _PyObject_CAST_CONST(op) ((const PyObject*)(op))
+#  define _PyObject_CAST_CONST(op) PYCAPI_COMPAT_CAST(const PyObject*, op)
 #endif
 
 
 // bpo-42262 added Py_NewRef() to Python 3.10.0a3
 #if PY_VERSION_HEX < 0x030A00A3 && !defined(Py_NewRef)
-static inline PyObject* _Py_NewRef(PyObject *obj)
+PYCAPI_COMPAT_STATIC_INLINE(PyObject*)
+_Py_NewRef(PyObject *obj)
 {
     Py_INCREF(obj);
     return obj;
@@ -74,7 +64,8 @@
 
 // bpo-42262 added Py_XNewRef() to Python 3.10.0a3
 #if PY_VERSION_HEX < 0x030A00A3 && !defined(Py_XNewRef)
-static inline PyObject* _Py_XNewRef(PyObject *obj)
+PYCAPI_COMPAT_STATIC_INLINE(PyObject*)
+_Py_XNewRef(PyObject *obj)
 {
     Py_XINCREF(obj);
     return obj;
@@ -85,7 +76,8 @@
 
 // See https://bugs.python.org/issue42522
 #if !defined(_Py_StealRef)
-static inline PyObject* __Py_StealRef(PyObject *obj)
+PYCAPI_COMPAT_STATIC_INLINE(PyObject*)
+__Py_StealRef(PyObject *obj)
 {
     Py_DECREF(obj);
     return obj;
@@ -96,7 +88,8 @@
 
 // See https://bugs.python.org/issue42522
 #if !defined(_Py_XStealRef)
-static inline PyObject* __Py_XStealRef(PyObject *obj)
+PYCAPI_COMPAT_STATIC_INLINE(PyObject*)
+__Py_XStealRef(PyObject *obj)
 {
     Py_XDECREF(obj);
     return obj;
@@ -107,7 +100,8 @@
 
 // bpo-39573 added Py_SET_REFCNT() to Python 3.9.0a4
 #if PY_VERSION_HEX < 0x030900A4 && !defined(Py_SET_REFCNT)
-static inline void _Py_SET_REFCNT(PyObject *ob, Py_ssize_t refcnt)
+PYCAPI_COMPAT_STATIC_INLINE(void)
+_Py_SET_REFCNT(PyObject *ob, Py_ssize_t refcnt)
 {
     ob->ob_refcnt = refcnt;
 }
@@ -152,7 +146,7 @@
 
 // bpo-39573 added Py_SET_TYPE() to Python 3.9.0a4
 #if PY_VERSION_HEX < 0x030900A4 && !defined(Py_SET_TYPE)
-static inline void
+PYCAPI_COMPAT_STATIC_INLINE(void)
 _Py_SET_TYPE(PyObject *ob, PyTypeObject *type)
 {
     ob->ob_type = type;
@@ -163,7 +157,7 @@
 
 // bpo-39573 added Py_SET_SIZE() to Python 3.9.0a4
 #if PY_VERSION_HEX < 0x030900A4 && !defined(Py_SET_SIZE)
-static inline void
+PYCAPI_COMPAT_STATIC_INLINE(void)
 _Py_SET_SIZE(PyVarObject *ob, Py_ssize_t size)
 {
     ob->ob_size = size;
@@ -174,47 +168,49 @@
 
 // bpo-40421 added PyFrame_GetCode() to Python 3.9.0b1
 #if PY_VERSION_HEX < 0x030900B1
-static inline PyCodeObject*
+PYCAPI_COMPAT_STATIC_INLINE(PyCodeObject*)
 PyFrame_GetCode(PyFrameObject *frame)
 {
-    assert(frame != NULL);
-    assert(frame->f_code != NULL);
-    return (PyCodeObject*)Py_NewRef(frame->f_code);
+    assert(frame != PYCAPI_COMPAT_NULL);
+    assert(frame->f_code != PYCAPI_COMPAT_NULL);
+    return PYCAPI_COMPAT_CAST(PyCodeObject*, Py_NewRef(frame->f_code));
 }
 #endif
 
-static inline PyCodeObject*
+PYCAPI_COMPAT_STATIC_INLINE(PyCodeObject*)
 _PyFrame_GetCodeBorrow(PyFrameObject *frame)
 {
-    return (PyCodeObject *)_Py_StealRef(PyFrame_GetCode(frame));
+    return PYCAPI_COMPAT_CAST(PyCodeObject *,
+                              _Py_StealRef(PyFrame_GetCode(frame)));
 }
 
 
 // bpo-40421 added PyFrame_GetCode() to Python 3.9.0b1
 #if PY_VERSION_HEX < 0x030900B1 && !defined(PYPY_VERSION)
-static inline PyFrameObject*
+PYCAPI_COMPAT_STATIC_INLINE(PyFrameObject*)
 PyFrame_GetBack(PyFrameObject *frame)
 {
-    assert(frame != NULL);
-    return (PyFrameObject*)Py_XNewRef(frame->f_back);
+    assert(frame != PYCAPI_COMPAT_NULL);
+    return PYCAPI_COMPAT_CAST(PyFrameObject*, Py_XNewRef(frame->f_back));
 }
 #endif
 
 #if !defined(PYPY_VERSION)
-static inline PyFrameObject*
+PYCAPI_COMPAT_STATIC_INLINE(PyFrameObject*)
 _PyFrame_GetBackBorrow(PyFrameObject *frame)
 {
-    return (PyFrameObject *)_Py_XStealRef(PyFrame_GetBack(frame));
+    return PYCAPI_COMPAT_CAST(PyFrameObject *,
+                              _Py_XStealRef(PyFrame_GetBack(frame)));
 }
 #endif
 
 
 // bpo-39947 added PyThreadState_GetInterpreter() to Python 3.9.0a5
 #if PY_VERSION_HEX < 0x030900A5
-static inline PyInterpreterState *
+PYCAPI_COMPAT_STATIC_INLINE(PyInterpreterState *)
 PyThreadState_GetInterpreter(PyThreadState *tstate)
 {
-    assert(tstate != NULL);
+    assert(tstate != PYCAPI_COMPAT_NULL);
     return tstate->interp;
 }
 #endif
@@ -222,37 +218,38 @@
 
 // bpo-40429 added PyThreadState_GetFrame() to Python 3.9.0b1
 #if PY_VERSION_HEX < 0x030900B1 && !defined(PYPY_VERSION)
-static inline PyFrameObject*
+PYCAPI_COMPAT_STATIC_INLINE(PyFrameObject*)
 PyThreadState_GetFrame(PyThreadState *tstate)
 {
-    assert(tstate != NULL);
-    return (PyFrameObject *)Py_XNewRef(tstate->frame);
+    assert(tstate != PYCAPI_COMPAT_NULL);
+    return PYCAPI_COMPAT_CAST(PyFrameObject *, Py_XNewRef(tstate->frame));
 }
 #endif
 
 #if !defined(PYPY_VERSION)
-static inline PyFrameObject*
+PYCAPI_COMPAT_STATIC_INLINE(PyFrameObject*)
 _PyThreadState_GetFrameBorrow(PyThreadState *tstate)
 {
-    return (PyFrameObject *)_Py_XStealRef(PyThreadState_GetFrame(tstate));
+    return PYCAPI_COMPAT_CAST(PyFrameObject*,
+                              _Py_XStealRef(PyThreadState_GetFrame(tstate)));
 }
 #endif
 
 
 // bpo-39947 added PyInterpreterState_Get() to Python 3.9.0a5
 #if PY_VERSION_HEX < 0x030900A5
-static inline PyInterpreterState *
+PYCAPI_COMPAT_STATIC_INLINE(PyInterpreterState*)
 PyInterpreterState_Get(void)
 {
     PyThreadState *tstate;
     PyInterpreterState *interp;
 
     tstate = PyThreadState_GET();
-    if (tstate == NULL) {
+    if (tstate == PYCAPI_COMPAT_NULL) {
         Py_FatalError("GIL released (tstate is NULL)");
     }
     interp = tstate->interp;
-    if (interp == NULL) {
+    if (interp == PYCAPI_COMPAT_NULL) {
         Py_FatalError("no current interpreter");
     }
     return interp;
@@ -262,18 +259,48 @@
 
 // bpo-39947 added PyInterpreterState_Get() to Python 3.9.0a6
 #if 0x030700A1 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x030900A6 && 
!defined(PYPY_VERSION)
-static inline uint64_t
+PYCAPI_COMPAT_STATIC_INLINE(uint64_t)
 PyThreadState_GetID(PyThreadState *tstate)
 {
-    assert(tstate != NULL);
+    assert(tstate != PYCAPI_COMPAT_NULL);
     return tstate->id;
 }
 #endif
 
+// bpo-43760 added PyThreadState_EnterTracing() to Python 3.11.0a2
+#if PY_VERSION_HEX < 0x030B00A2 && !defined(PYPY_VERSION)
+PYCAPI_COMPAT_STATIC_INLINE(void)
+PyThreadState_EnterTracing(PyThreadState *tstate)
+{
+    tstate->tracing++;
+#if PY_VERSION_HEX >= 0x030A00A1
+    tstate->cframe->use_tracing = 0;
+#else
+    tstate->use_tracing = 0;
+#endif
+}
+#endif
+
+// bpo-43760 added PyThreadState_LeaveTracing() to Python 3.11.0a2
+#if PY_VERSION_HEX < 0x030B00A2 && !defined(PYPY_VERSION)
+PYCAPI_COMPAT_STATIC_INLINE(void)
+PyThreadState_LeaveTracing(PyThreadState *tstate)
+{
+    int use_tracing = (tstate->c_tracefunc != PYCAPI_COMPAT_NULL
+                       || tstate->c_profilefunc != PYCAPI_COMPAT_NULL);
+    tstate->tracing--;
+#if PY_VERSION_HEX >= 0x030A00A1
+    tstate->cframe->use_tracing = use_tracing;
+#else
+    tstate->use_tracing = use_tracing;
+#endif
+}
+#endif
+
 
 // bpo-37194 added PyObject_CallNoArgs() to Python 3.9.0a1
 #if PY_VERSION_HEX < 0x030900A1
-static inline PyObject*
+PYCAPI_COMPAT_STATIC_INLINE(PyObject*)
 PyObject_CallNoArgs(PyObject *func)
 {
     return PyObject_CallFunctionObjArgs(func, NULL);
@@ -284,7 +311,7 @@
 // bpo-39245 made PyObject_CallOneArg() public (previously called
 // _PyObject_CallOneArg) in Python 3.9.0a4
 #if PY_VERSION_HEX < 0x030900A4
-static inline PyObject*
+PYCAPI_COMPAT_STATIC_INLINE(PyObject*)
 PyObject_CallOneArg(PyObject *func, PyObject *arg)
 {
     return PyObject_CallFunctionObjArgs(func, arg, NULL);
@@ -294,12 +321,12 @@
 
 // bpo-1635741 added PyModule_AddObjectRef() to Python 3.10.0a3
 #if PY_VERSION_HEX < 0x030A00A3
-static inline int
-PyModule_AddObjectRef(PyObject *module, const char *name, PyObject *value)
+PYCAPI_COMPAT_STATIC_INLINE(int)
+PyModule_AddObjectRef(PyObject *mod, const char *name, PyObject *value)
 {
     int res;
     Py_XINCREF(value);
-    res = PyModule_AddObject(module, name, value);
+    res = PyModule_AddObject(mod, name, value);
     if (res < 0) {
         Py_XDECREF(value);
     }
@@ -310,8 +337,8 @@
 
 // bpo-40024 added PyModule_AddType() to Python 3.9.0a5
 #if PY_VERSION_HEX < 0x030900A5
-static inline int
-PyModule_AddType(PyObject *module, PyTypeObject *type)
+PYCAPI_COMPAT_STATIC_INLINE(int)
+PyModule_AddType(PyObject *mod, PyTypeObject *type)
 {
     const char *name, *dot;
 
@@ -321,13 +348,13 @@
 
     // inline _PyType_Name()
     name = type->tp_name;
-    assert(name != NULL);
+    assert(name != PYCAPI_COMPAT_NULL);
     dot = strrchr(name, '.');
-    if (dot != NULL) {
+    if (dot != PYCAPI_COMPAT_NULL) {
         name = dot + 1;
     }
 
-    return PyModule_AddObjectRef(module, name, (PyObject *)type);
+    return PyModule_AddObjectRef(mod, name, _PyObject_CAST(type));
 }
 #endif
 
@@ -335,7 +362,7 @@
 // bpo-40241 added PyObject_GC_IsTracked() to Python 3.9.0a6.
 // bpo-4688 added _PyObject_GC_IS_TRACKED() to Python 2.7.0a2.
 #if PY_VERSION_HEX < 0x030900A6 && !defined(PYPY_VERSION)
-static inline int
+PYCAPI_COMPAT_STATIC_INLINE(int)
 PyObject_GC_IsTracked(PyObject* obj)
 {
     return (PyObject_IS_GC(obj) && _PyObject_GC_IS_TRACKED(obj));
@@ -345,17 +372,18 @@
 // bpo-40241 added PyObject_GC_IsFinalized() to Python 3.9.0a6.
 // bpo-18112 added _PyGCHead_FINALIZED() to Python 3.4.0 final.
 #if PY_VERSION_HEX < 0x030900A6 && PY_VERSION_HEX >= 0x030400F0 && 
!defined(PYPY_VERSION)
-static inline int
+PYCAPI_COMPAT_STATIC_INLINE(int)
 PyObject_GC_IsFinalized(PyObject *obj)
 {
-    return (PyObject_IS_GC(obj) && _PyGCHead_FINALIZED((PyGC_Head *)(obj)-1));
+    PyGC_Head *gc = PYCAPI_COMPAT_CAST(PyGC_Head *, obj) - 1;
+    return (PyObject_IS_GC(obj) && _PyGCHead_FINALIZED(gc));
 }
 #endif
 
 
 // bpo-39573 added Py_IS_TYPE() to Python 3.9.0a4
 #if PY_VERSION_HEX < 0x030900A4 && !defined(Py_IS_TYPE)
-static inline int
+PYCAPI_COMPAT_STATIC_INLINE(int)
 _Py_IS_TYPE(const PyObject *ob, const PyTypeObject *type) {
     return ob->ob_type == type;
 }
@@ -363,6 +391,45 @@
 #endif
 
 
+// bpo-46906 added PyFloat_Pack2() and PyFloat_Unpack2() to Python 3.11a7.
+// bpo-11734 added _PyFloat_Pack2() and _PyFloat_Unpack2() to Python 3.6.0b1.
+// Python 3.11a2 moved _PyFloat_Pack2() and _PyFloat_Unpack2() to the internal
+// C API: Python 3.11a2-3.11a6 versions are not supported.
+#if 0x030600B1 <= PY_VERSION_HEX && PY_VERSION_HEX <= 0x030B00A1 && 
!defined(PYPY_VERSION)
+PYCAPI_COMPAT_STATIC_INLINE(int)
+PyFloat_Pack2(double x, char *p, int le)
+{ return _PyFloat_Pack2(x, (unsigned char*)p, le); }
+
+PYCAPI_COMPAT_STATIC_INLINE(double)
+PyFloat_Unpack2(const char *p, int le)
+{ return _PyFloat_Unpack2((const unsigned char *)p, le); }
+#endif
+
+
+// bpo-46906 added PyFloat_Pack4(), PyFloat_Pack8(), PyFloat_Unpack4() and
+// PyFloat_Unpack8() to Python 3.11a7.
+// Python 3.11a2 moved _PyFloat_Pack4(), _PyFloat_Pack8(), _PyFloat_Unpack4()
+// and _PyFloat_Unpack8() to the internal C API: Python 3.11a2-3.11a6 versions
+// are not supported.
+#if PY_VERSION_HEX <= 0x030B00A1 && !defined(PYPY_VERSION)
+PYCAPI_COMPAT_STATIC_INLINE(int)
+PyFloat_Pack4(double x, char *p, int le)
+{ return _PyFloat_Pack4(x, (unsigned char*)p, le); }
+
+PYCAPI_COMPAT_STATIC_INLINE(int)
+PyFloat_Pack8(double x, char *p, int le)
+{ return _PyFloat_Pack8(x, (unsigned char*)p, le); }
+
+PYCAPI_COMPAT_STATIC_INLINE(double)
+PyFloat_Unpack4(const char *p, int le)
+{ return _PyFloat_Unpack4((const unsigned char *)p, le); }
+
+PYCAPI_COMPAT_STATIC_INLINE(double)
+PyFloat_Unpack8(const char *p, int le)
+{ return _PyFloat_Unpack8((const unsigned char *)p, le); }
+#endif
+
+
 // Py_UNUSED() was added to Python 3.4.0b2.
 #if PY_VERSION_HEX < 0x030400B2 && !defined(Py_UNUSED)
 #  if defined(__GNUC__) || defined(__clang__)
@@ -373,11 +440,6 @@
 #endif
 
 
-#ifdef PYTHONCAPI_COMPAT_MSC_INLINE
-#  undef inline
-#  undef PYTHONCAPI_COMPAT_MSC_INLINE
-#endif
-
 #ifdef __cplusplus
 }
 #endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/immutables.egg-info/PKG-INFO 
new/immutables-0.18/immutables.egg-info/PKG-INFO
--- old/immutables-0.16/immutables.egg-info/PKG-INFO    2021-08-07 
21:41:15.000000000 +0200
+++ new/immutables-0.18/immutables.egg-info/PKG-INFO    2022-05-22 
08:24:34.000000000 +0200
@@ -1,12 +1,11 @@
 Metadata-Version: 2.1
 Name: immutables
-Version: 0.16
+Version: 0.18
 Summary: Immutable Collections
 Home-page: https://github.com/MagicStack/immutables
 Author: MagicStack Inc
 Author-email: he...@magic.io
 License: Apache License, Version 2.0
-Platform: UNKNOWN
 Classifier: License :: OSI Approved :: Apache Software License
 Classifier: Intended Audience :: Developers
 Classifier: Programming Language :: Python :: 3 :: Only
@@ -148,5 +147,3 @@
 -------
 
 Apache 2.0
-
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/immutables.egg-info/SOURCES.txt 
new/immutables-0.18/immutables.egg-info/SOURCES.txt
--- old/immutables-0.16/immutables.egg-info/SOURCES.txt 2021-08-07 
21:41:15.000000000 +0200
+++ new/immutables-0.18/immutables.egg-info/SOURCES.txt 2022-05-22 
08:24:35.000000000 +0200
@@ -4,7 +4,6 @@
 NOTICE
 README.rst
 bench.png
-mypy.ini
 pyproject.toml
 setup.py
 immutables/__init__.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/immutables.egg-info/requires.txt 
new/immutables-0.18/immutables.egg-info/requires.txt
--- old/immutables-0.16/immutables.egg-info/requires.txt        2021-08-07 
21:41:15.000000000 +0200
+++ new/immutables-0.18/immutables.egg-info/requires.txt        2022-05-22 
08:24:35.000000000 +0200
@@ -5,5 +5,5 @@
 [test]
 flake8~=3.8.4
 pycodestyle~=2.6.0
-mypy>=0.910
+mypy==0.942
 pytest~=6.2.4
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/mypy.ini new/immutables-0.18/mypy.ini
--- old/immutables-0.16/mypy.ini        2021-08-07 21:41:10.000000000 +0200
+++ new/immutables-0.18/mypy.ini        1970-01-01 01:00:00.000000000 +0100
@@ -1,9 +0,0 @@
-[mypy]
-incremental = True
-strict = True
-
-[mypy-immutables.map]
-ignore_errors = True
-
-[mypy-immutables._testutils]
-ignore_errors = True
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/pyproject.toml 
new/immutables-0.18/pyproject.toml
--- old/immutables-0.16/pyproject.toml  2021-08-07 21:41:10.000000000 +0200
+++ new/immutables-0.18/pyproject.toml  2022-05-22 08:24:25.000000000 +0200
@@ -1,6 +1,25 @@
 [project]
+name = 'immutables'
 requires-python = ">=3.6"
 
 [build-system]
 requires = ["setuptools>=42", "wheel"]
 build-backend = "setuptools.build_meta"
+
+[tool.pytest.ini_options]
+minversion = "6.0"
+addopts = "--capture=no --assert=plain --strict-markers --tb=native 
--import-mode=importlib"
+testpaths = "tests"
+filterwarnings = "default"
+
+[tool.mypy]
+incremental = true
+strict = true
+
+[[tool.mypy.overrides]]
+module = "immutables.map"
+ignore_errors = true
+
+[[tool.mypy.overrides]]
+module = "immutables._testutils"
+ignore_errors = true
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/setup.py new/immutables-0.18/setup.py
--- old/immutables-0.16/setup.py        2021-08-07 21:41:10.000000000 +0200
+++ new/immutables-0.18/setup.py        2022-05-22 08:24:25.000000000 +0200
@@ -10,7 +10,7 @@
     # (example breakage: https://gitlab.com/pycqa/flake8/issues/427)
     'flake8~=3.8.4',
     'pycodestyle~=2.6.0',
-    'mypy>=0.910',
+    'mypy==0.942',
     'pytest~=6.2.4',
 ]
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/immutables-0.16/tests/test_map.py 
new/immutables-0.18/tests/test_map.py
--- old/immutables-0.16/tests/test_map.py       2021-08-07 21:41:10.000000000 
+0200
+++ new/immutables-0.18/tests/test_map.py       2022-05-22 08:24:25.000000000 
+0200
@@ -254,6 +254,40 @@
             self.assertEqual(len(h), 0)
             self.assertEqual(list(h.items()), [])
 
+    def test_map_collision_3(self):
+        # Test that iteration works with the deepest tree possible.
+
+        C = HashKey(0b10000000_00000000_00000000_00000000, 'C')
+        D = HashKey(0b10000000_00000000_00000000_00000000, 'D')
+
+        E = HashKey(0b00000000_00000000_00000000_00000000, 'E')
+
+        h = self.Map()
+        h = h.set(C, 'C')
+        h = h.set(D, 'D')
+        h = h.set(E, 'E')
+
+        # BitmapNode(size=2 count=1 bitmap=0b1):
+        #   NULL:
+        #     BitmapNode(size=2 count=1 bitmap=0b1):
+        #       NULL:
+        #         BitmapNode(size=2 count=1 bitmap=0b1):
+        #           NULL:
+        #             BitmapNode(size=2 count=1 bitmap=0b1):
+        #               NULL:
+        #                 BitmapNode(size=2 count=1 bitmap=0b1):
+        #                   NULL:
+        #                     BitmapNode(size=2 count=1 bitmap=0b1):
+        #                       NULL:
+        #                         BitmapNode(size=4 count=2 bitmap=0b101):
+        #                           <Key name:E hash:0>: 'E'
+        #                           NULL:
+        #                             CollisionNode(size=4 id=0x107a24520):
+        #                               <Key name:C hash:2147483648>: 'C'
+        #                               <Key name:D hash:2147483648>: 'D'
+
+        self.assertEqual({k.name for k in h.keys()}, {'C', 'D', 'E'})
+
     def test_map_stress_02(self):
         COLLECTION_SIZE = 20000
         TEST_ITERS_EVERY = 647

Reply via email to