Add PyObject_HEAD to clang-format

HTGtoUGids
David Gobbi 2 years ago
parent 58561e6847
commit 33e13329a0

@ -16,6 +16,8 @@ ColumnLimit: 100
SpaceAfterTemplateKeyword: true
Standard: Cpp11
StatementMacros:
- PyObject_HEAD
- PyObject_VAR_HEAD
- vtkAbstractTypeMacro
- vtkTypeMacro
- vtkBaseTypeMacro

@ -26,7 +26,8 @@
struct vtkPythonStdStreamCaptureHelper
{
PyObject_HEAD int softspace; // Used by print to keep track of its state.
PyObject_HEAD
int softspace; // Used by print to keep track of its state.
bool DumpToError;
void Write(const char* string)

@ -57,13 +57,14 @@ public:
// plus a pointer to the associated vtkObjectBase and PyVTKClass.
struct PyVTKObject
{
PyObject_HEAD PyObject* vtk_dict; // each object has its own dict
PyObject* vtk_weakreflist; // list of weak references via python
PyVTKClass* vtk_class; // information about the class
vtkObjectBase* vtk_ptr; // pointer to the C++ object
Py_ssize_t* vtk_buffer; // ndims, shape, strides for Py_buffer
unsigned long* vtk_observers; // used to find our observers
unsigned int vtk_flags; // flags (see list above)
PyObject_HEAD
PyObject* vtk_dict; // each object has its own dict
PyObject* vtk_weakreflist; // list of weak references via python
PyVTKClass* vtk_class; // information about the class
vtkObjectBase* vtk_ptr; // pointer to the C++ object
Py_ssize_t* vtk_buffer; // ndims, shape, strides for Py_buffer
unsigned long* vtk_observers; // used to find our observers
unsigned int vtk_flags; // flags (see list above)
};
extern VTKWRAPPINGPYTHONCORE_EXPORT PyGetSetDef PyVTKObject_GetSet[];

@ -30,7 +30,8 @@
// type int or float.
struct PyVTKReference
{
PyObject_HEAD PyObject* value;
PyObject_HEAD
PyObject* value;
};
extern PyTypeObject PyVTKReference_Type;

@ -60,7 +60,8 @@ public:
// own structs.
struct PyVTKSpecialObject
{
PyObject_HEAD PyVTKSpecialType* vtk_info;
PyObject_HEAD
PyVTKSpecialType* vtk_info;
void* vtk_ptr;
long vtk_hash;
};

Loading…
Cancel
Save