From 94311a205af8c9d0726c4637b37781e0a01885db Mon Sep 17 00:00:00 2001
From: "Joachim Wuttke (h)" <j.wuttke@fz-juelich.de>
Date: Fri, 8 Mar 2024 12:12:37 +0100
Subject: [PATCH] PyObjectPtr must not be exposed to Swig

---
 PyCore/Embed/PyObjectPtr.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/PyCore/Embed/PyObjectPtr.h b/PyCore/Embed/PyObjectPtr.h
index aea8fe906e1..af28d305a49 100644
--- a/PyCore/Embed/PyObjectPtr.h
+++ b/PyCore/Embed/PyObjectPtr.h
@@ -12,6 +12,9 @@
 //
 //  ************************************************************************************************
 
+#ifdef SWIG
+#error no need to expose this header to Swig
+#endif // SWIG
 #ifndef BORNAGAIN_PYTHON
 #error this header requires Python support
 #endif
-- 
GitLab