diff --git a/src/wrapper/_pvt_struct_v3.cpp b/src/wrapper/_pvt_struct_v3.cpp
index 61e1cf8468a396481ac0dc338a306175d2da2915..c911c54a94f566ea9419753a8e015bf8d25e64b6 100644
--- a/src/wrapper/_pvt_struct_v3.cpp
+++ b/src/wrapper/_pvt_struct_v3.cpp
@@ -10,7 +10,9 @@
 #include <ctype.h>
 #include "numpy_init.hpp"
 
-// static PyTypeObject PyStructType;
+namespace {
+extern PyTypeObject PyStructType;
+}
 
 /* The translation function for each format character is table driven */
 typedef struct _formatdef {
@@ -1413,7 +1415,7 @@ static PyGetSetDef s_getsetlist[] = {
     {NULL} /* sentinel */
 };
 
-static
+namespace {
 PyTypeObject PyStructType = {
     PyVarObject_HEAD_INIT(NULL, 0)
     "Struct",
@@ -1455,6 +1457,7 @@ PyTypeObject PyStructType = {
     s_new,                              /* tp_new */
     PyObject_Del,               /* tp_free */
 };
+}
 
 
 /* ---- Standalone functions  ---- */