From 434882af22b8c1941f078557b6411a1af63d099b Mon Sep 17 00:00:00 2001
From: Stefan Behnel <stefan_ml@behnel.de>
Date: Tue, 20 Apr 2021 18:38:36 +0200
Subject: [PATCH] Avoid C compiler warning in Py<3.7 when the
 "__Pyx_PyObject_CallMethod0" helper function is unused.

---
 Cython/Utility/ExtensionTypes.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/Cython/Utility/ExtensionTypes.c b/Cython/Utility/ExtensionTypes.c
index 04d95a4d4..b43f5018c 100644
--- a/Cython/Utility/ExtensionTypes.c
+++ b/Cython/Utility/ExtensionTypes.c
@@ -108,6 +108,9 @@ static int __Pyx_PyType_Ready(PyTypeObject *t) {
         // Other than this check, the Py_TPFLAGS_HEAPTYPE flag is unused
         // in PyType_Ready().
         t->tp_flags |= Py_TPFLAGS_HEAPTYPE;
+#else
+        // avoid C warning about unused helper function
+        (void)__Pyx_PyObject_CallMethod0;
 #endif
 
     r = PyType_Ready(t);
-- 
2.30.9