From: Steve Langasek Date: Wed, 11 Mar 2020 10:49:13 +0000 (-0400) Subject: fix compatibility with Python 3.8 X-Git-Tag: archive/raspbian/5.3.0-13+rpi1^2~2 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=bde9eed19f34da456ec735f0252f4a968d68be46;p=gringo.git fix compatibility with Python 3.8 Last-Update: 2020-02-20 Forwarded: no Bug-Debian: https://bugs.debian.org/951707 Python 3.8 changes the type of an element of the PyTypeObject struct (https://www.python.org/dev/peps/pep-0590/) leading to compiler errors. Gbp-Pq: Name python3.8-compat.patch --- diff --git a/libpyclingo/pyclingo.cc b/libpyclingo/pyclingo.cc index 39effee..97473b6 100644 --- a/libpyclingo/pyclingo.cc +++ b/libpyclingo/pyclingo.cc @@ -1128,7 +1128,11 @@ PyTypeObject ObjectBase::type = { sizeof(T), // tp_basicsize 0, // tp_itemsize PythonDetail::Get_tp_dealloc::value, // tp_dealloc +#if PY_VERSION_HEX >= 0x03080000 + 0, // tp_vectorcall_offset +#else nullptr, // tp_print +#endif nullptr, // tp_getattr nullptr, // tp_setattr nullptr, // tp_compare