From 91694b9b58ab953f3b313be9389cc1303e472fc2 Mon Sep 17 00:00:00 2001 From: Jacques Lucke Date: Fri, 7 Aug 2020 09:50:34 +0200 Subject: Code Style: use "#pragma once" in source directory This replaces header include guards with `#pragma once`. A couple of include guards are not removed yet (e.g. `__RNA_TYPES_H__`), because they are used in other places. This patch has been generated by P1561 followed by `make format`. Differential Revision: https://developer.blender.org/D8466 --- source/blender/python/BPY_extern.h | 5 +---- source/blender/python/BPY_extern_clog.h | 5 +---- source/blender/python/bmesh/bmesh_py_api.h | 5 +---- source/blender/python/bmesh/bmesh_py_geometry.h | 5 +---- source/blender/python/bmesh/bmesh_py_ops.h | 5 +---- source/blender/python/bmesh/bmesh_py_ops_call.h | 5 +---- source/blender/python/bmesh/bmesh_py_types.h | 5 +---- source/blender/python/bmesh/bmesh_py_types_customdata.h | 5 +---- source/blender/python/bmesh/bmesh_py_types_meshdata.h | 5 +---- source/blender/python/bmesh/bmesh_py_types_select.h | 5 +---- source/blender/python/bmesh/bmesh_py_utils.h | 5 +---- source/blender/python/generic/bgl.h | 5 +---- source/blender/python/generic/bl_math_py_api.h | 5 +---- source/blender/python/generic/blf_py_api.h | 5 +---- source/blender/python/generic/idprop_py_api.h | 5 +---- source/blender/python/generic/imbuf_py_api.h | 5 +---- source/blender/python/generic/python_utildefines.h | 5 +---- source/blender/python/gpu/gpu_py_api.h | 5 +---- source/blender/python/gpu/gpu_py_batch.h | 5 +---- source/blender/python/gpu/gpu_py_element.h | 5 +---- source/blender/python/gpu/gpu_py_matrix.h | 5 +---- source/blender/python/gpu/gpu_py_offscreen.h | 5 +---- source/blender/python/gpu/gpu_py_select.h | 5 +---- source/blender/python/gpu/gpu_py_shader.h | 5 +---- source/blender/python/gpu/gpu_py_types.h | 5 +---- source/blender/python/gpu/gpu_py_vertex_buffer.h | 5 +---- source/blender/python/gpu/gpu_py_vertex_format.h | 5 +---- source/blender/python/intern/bpy.h | 5 +---- source/blender/python/intern/bpy_app.h | 5 +---- source/blender/python/intern/bpy_app_alembic.h | 5 +---- source/blender/python/intern/bpy_app_build_options.h | 5 +---- source/blender/python/intern/bpy_app_ffmpeg.h | 5 +---- source/blender/python/intern/bpy_app_handlers.h | 5 +---- source/blender/python/intern/bpy_app_icons.h | 5 +---- source/blender/python/intern/bpy_app_ocio.h | 5 +---- source/blender/python/intern/bpy_app_oiio.h | 5 +---- source/blender/python/intern/bpy_app_opensubdiv.h | 5 +---- source/blender/python/intern/bpy_app_openvdb.h | 5 +---- source/blender/python/intern/bpy_app_sdl.h | 5 +---- source/blender/python/intern/bpy_app_timers.h | 5 +---- source/blender/python/intern/bpy_app_translations.h | 5 +---- source/blender/python/intern/bpy_app_usd.h | 5 +---- source/blender/python/intern/bpy_capi_utils.h | 5 +---- source/blender/python/intern/bpy_driver.h | 5 +---- source/blender/python/intern/bpy_gizmo_wrap.h | 5 +---- source/blender/python/intern/bpy_intern_string.h | 5 +---- source/blender/python/intern/bpy_library.h | 5 +---- source/blender/python/intern/bpy_msgbus.h | 5 +---- source/blender/python/intern/bpy_operator.h | 5 +---- source/blender/python/intern/bpy_operator_wrap.h | 5 +---- source/blender/python/intern/bpy_path.h | 5 +---- source/blender/python/intern/bpy_props.h | 5 +---- source/blender/python/intern/bpy_rna.h | 5 +---- source/blender/python/intern/bpy_rna_anim.h | 5 +---- source/blender/python/intern/bpy_rna_callback.h | 5 +---- source/blender/python/intern/bpy_rna_driver.h | 5 +---- source/blender/python/intern/bpy_rna_gizmo.h | 5 +---- source/blender/python/intern/bpy_rna_id_collection.h | 5 +---- source/blender/python/intern/bpy_rna_types_capi.h | 5 +---- source/blender/python/intern/bpy_traceback.h | 5 +---- source/blender/python/intern/bpy_utils_previews.h | 5 +---- source/blender/python/intern/bpy_utils_units.h | 5 +---- source/blender/python/mathutils/mathutils.h | 5 +---- source/blender/python/mathutils/mathutils_Color.h | 5 +---- source/blender/python/mathutils/mathutils_Euler.h | 5 +---- source/blender/python/mathutils/mathutils_Matrix.h | 5 +---- source/blender/python/mathutils/mathutils_Quaternion.h | 5 +---- source/blender/python/mathutils/mathutils_Vector.h | 5 +---- source/blender/python/mathutils/mathutils_bvhtree.h | 5 +---- source/blender/python/mathutils/mathutils_geometry.h | 5 +---- source/blender/python/mathutils/mathutils_interpolate.h | 5 +---- source/blender/python/mathutils/mathutils_kdtree.h | 5 +---- source/blender/python/mathutils/mathutils_noise.h | 5 +---- 73 files changed, 73 insertions(+), 292 deletions(-) (limited to 'source/blender/python') diff --git a/source/blender/python/BPY_extern.h b/source/blender/python/BPY_extern.h index 42472dda42c..da9b5d642ef 100644 --- a/source/blender/python/BPY_extern.h +++ b/source/blender/python/BPY_extern.h @@ -18,8 +18,7 @@ * \ingroup python */ -#ifndef __BPY_EXTERN_H__ -#define __BPY_EXTERN_H__ +#pragma once struct AnimationEvalContext; struct ChannelDriver; /* DNA_anim_types.h */ @@ -141,5 +140,3 @@ const char *BPY_app_translations_py_pgettext(const char *msgctxt, const char *ms #ifdef __cplusplus } /* extern "C" */ #endif - -#endif /* __BPY_EXTERN_H__ */ diff --git a/source/blender/python/BPY_extern_clog.h b/source/blender/python/BPY_extern_clog.h index d610dc1c7ba..14b57b4cc5c 100644 --- a/source/blender/python/BPY_extern_clog.h +++ b/source/blender/python/BPY_extern_clog.h @@ -20,11 +20,8 @@ * Logging defines. */ -#ifndef __BPY_EXTERN_CLOG_H__ -#define __BPY_EXTERN_CLOG_H__ +#pragma once /* bpy_interface.c */ extern struct CLG_LogRef *BPY_LOG_RNA; extern struct CLG_LogRef *BPY_LOG_CONTEXT; - -#endif /* __BPY_EXTERN_CLOG_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_api.h b/source/blender/python/bmesh/bmesh_py_api.h index 9f227b21440..357f416f266 100644 --- a/source/blender/python/bmesh/bmesh_py_api.h +++ b/source/blender/python/bmesh/bmesh_py_api.h @@ -21,9 +21,6 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_API_H__ -#define __BMESH_PY_API_H__ +#pragma once PyObject *BPyInit_bmesh(void); - -#endif /* __BMESH_PY_API_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_geometry.h b/source/blender/python/bmesh/bmesh_py_geometry.h index 98d336828dc..dcb8c59f68b 100644 --- a/source/blender/python/bmesh/bmesh_py_geometry.h +++ b/source/blender/python/bmesh/bmesh_py_geometry.h @@ -21,9 +21,6 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_GEOMETRY_H__ -#define __BMESH_PY_GEOMETRY_H__ +#pragma once PyObject *BPyInit_bmesh_geometry(void); - -#endif /* __BMESH_PY_GEOMETRY_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_ops.h b/source/blender/python/bmesh/bmesh_py_ops.h index a4a12bbef61..442af51fd17 100644 --- a/source/blender/python/bmesh/bmesh_py_ops.h +++ b/source/blender/python/bmesh/bmesh_py_ops.h @@ -21,9 +21,6 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_OPS_H__ -#define __BMESH_PY_OPS_H__ +#pragma once PyObject *BPyInit_bmesh_ops(void); - -#endif /* __BMESH_PY_OPS_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_ops_call.h b/source/blender/python/bmesh/bmesh_py_ops_call.h index 7b6611cd61d..6d9ceec73f6 100644 --- a/source/blender/python/bmesh/bmesh_py_ops_call.h +++ b/source/blender/python/bmesh/bmesh_py_ops_call.h @@ -21,8 +21,7 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_OPS_CALL_H__ -#define __BMESH_PY_OPS_CALL_H__ +#pragma once typedef struct { PyObject_HEAD /* required python macro */ @@ -30,5 +29,3 @@ typedef struct { } BPy_BMeshOpFunc; PyObject *BPy_BMO_call(BPy_BMeshOpFunc *self, PyObject *args, PyObject *kw); - -#endif /* __BMESH_PY_OPS_CALL_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_types.h b/source/blender/python/bmesh/bmesh_py_types.h index 74bfbcec3c7..7ac3c4bf3cc 100644 --- a/source/blender/python/bmesh/bmesh_py_types.h +++ b/source/blender/python/bmesh/bmesh_py_types.h @@ -21,8 +21,7 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_TYPES_H__ -#define __BMESH_PY_TYPES_H__ +#pragma once extern PyTypeObject BPy_BMesh_Type; extern PyTypeObject BPy_BMVert_Type; @@ -228,5 +227,3 @@ extern struct PyC_FlagSet bpy_bm_htype_vert_edge_face_flags[]; extern struct PyC_FlagSet bpy_bm_htype_all_flags[]; extern struct PyC_FlagSet bpy_bm_hflag_all_flags[]; #endif - -#endif /* __BMESH_PY_TYPES_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_types_customdata.h b/source/blender/python/bmesh/bmesh_py_types_customdata.h index 95836707e3d..3173813a912 100644 --- a/source/blender/python/bmesh/bmesh_py_types_customdata.h +++ b/source/blender/python/bmesh/bmesh_py_types_customdata.h @@ -21,8 +21,7 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_TYPES_CUSTOMDATA_H__ -#define __BMESH_PY_TYPES_CUSTOMDATA_H__ +#pragma once /* all use BPy_BMLayerAccess struct */ extern PyTypeObject BPy_BMLayerAccessVert_Type; @@ -67,5 +66,3 @@ void BPy_BM_init_types_customdata(void); /* __getitem__ / __setitem__ */ PyObject *BPy_BMLayerItem_GetItem(BPy_BMElem *py_ele, BPy_BMLayerItem *py_layer); int BPy_BMLayerItem_SetItem(BPy_BMElem *py_ele, BPy_BMLayerItem *py_layer, PyObject *value); - -#endif /* __BMESH_PY_TYPES_CUSTOMDATA_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_types_meshdata.h b/source/blender/python/bmesh/bmesh_py_types_meshdata.h index 5211c30ec7e..58f31a9807e 100644 --- a/source/blender/python/bmesh/bmesh_py_types_meshdata.h +++ b/source/blender/python/bmesh/bmesh_py_types_meshdata.h @@ -21,8 +21,7 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_TYPES_MESHDATA_H__ -#define __BMESH_PY_TYPES_MESHDATA_H__ +#pragma once extern PyTypeObject BPy_BMLoopUV_Type; extern PyTypeObject BPy_BMDeformVert_Type; @@ -51,5 +50,3 @@ int BPy_BMDeformVert_AssignPyObject(struct MDeformVert *dvert, PyObject *value); PyObject *BPy_BMDeformVert_CreatePyObject(struct MDeformVert *dvert); void BPy_BM_init_types_meshdata(void); - -#endif /* __BMESH_PY_TYPES_MESHDATA_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_types_select.h b/source/blender/python/bmesh/bmesh_py_types_select.h index 593857a5083..c33aa3675c5 100644 --- a/source/blender/python/bmesh/bmesh_py_types_select.h +++ b/source/blender/python/bmesh/bmesh_py_types_select.h @@ -21,8 +21,7 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_TYPES_SELECT_H__ -#define __BMESH_PY_TYPES_SELECT_H__ +#pragma once struct BPy_BMesh; @@ -46,5 +45,3 @@ void BPy_BM_init_types_select(void); PyObject *BPy_BMEditSel_CreatePyObject(BMesh *bm); PyObject *BPy_BMEditSelIter_CreatePyObject(BMesh *bm); int BPy_BMEditSel_Assign(struct BPy_BMesh *self, PyObject *value); - -#endif /* __BMESH_PY_SELECT_H__ */ diff --git a/source/blender/python/bmesh/bmesh_py_utils.h b/source/blender/python/bmesh/bmesh_py_utils.h index a6f4f22bf8b..27eccca4535 100644 --- a/source/blender/python/bmesh/bmesh_py_utils.h +++ b/source/blender/python/bmesh/bmesh_py_utils.h @@ -21,9 +21,6 @@ * \ingroup pybmesh */ -#ifndef __BMESH_PY_UTILS_H__ -#define __BMESH_PY_UTILS_H__ +#pragma once PyObject *BPyInit_bmesh_utils(void); - -#endif /* __BMESH_PY_UTILS_H__ */ diff --git a/source/blender/python/generic/bgl.h b/source/blender/python/generic/bgl.h index 8c81dc48340..ee8c293945a 100644 --- a/source/blender/python/generic/bgl.h +++ b/source/blender/python/generic/bgl.h @@ -18,8 +18,7 @@ * \ingroup pygen */ -#ifndef __BGL_H__ -#define __BGL_H__ +#pragma once PyObject *BPyInit_bgl(void); @@ -52,5 +51,3 @@ typedef struct _Buffer { /** The type object */ extern PyTypeObject BGL_bufferType; - -#endif /* __BGL_H__ */ diff --git a/source/blender/python/generic/bl_math_py_api.h b/source/blender/python/generic/bl_math_py_api.h index 9183573abfc..484304948f3 100644 --- a/source/blender/python/generic/bl_math_py_api.h +++ b/source/blender/python/generic/bl_math_py_api.h @@ -19,9 +19,6 @@ * \ingroup pygen */ -#ifndef __BL_MATH_PY_API_H__ -#define __BL_MATH_PY_API_H__ +#pragma once PyMODINIT_FUNC BPyInit_bl_math(void); - -#endif /* __BL_MATH_PY_API_H__ */ diff --git a/source/blender/python/generic/blf_py_api.h b/source/blender/python/generic/blf_py_api.h index 919272df942..c47edd1eaab 100644 --- a/source/blender/python/generic/blf_py_api.h +++ b/source/blender/python/generic/blf_py_api.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __BLF_PY_API_H__ -#define __BLF_PY_API_H__ +#pragma once /** \file * \ingroup pygen @@ -24,5 +23,3 @@ #include PyObject *BPyInit_blf(void); - -#endif /* __BLF_PY_API_H__ */ diff --git a/source/blender/python/generic/idprop_py_api.h b/source/blender/python/generic/idprop_py_api.h index 49094f95ecb..478dc99f73d 100644 --- a/source/blender/python/generic/idprop_py_api.h +++ b/source/blender/python/generic/idprop_py_api.h @@ -18,8 +18,7 @@ * \ingroup pygen */ -#ifndef __IDPROP_PY_API_H__ -#define __IDPROP_PY_API_H__ +#pragma once struct BPy_IDGroup_Iter; struct ID; @@ -68,5 +67,3 @@ PyObject *BPyInit_idprop(void); #define IDPROP_ITER_KEYS 0 #define IDPROP_ITER_ITEMS 1 - -#endif /* __IDPROP_PY_API_H__ */ diff --git a/source/blender/python/generic/imbuf_py_api.h b/source/blender/python/generic/imbuf_py_api.h index 2dea925a9f2..897423415b3 100644 --- a/source/blender/python/generic/imbuf_py_api.h +++ b/source/blender/python/generic/imbuf_py_api.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __IMBUF_PY_API_H__ -#define __IMBUF_PY_API_H__ +#pragma once /** \file * \ingroup pygen @@ -24,5 +23,3 @@ PyObject *BPyInit_imbuf(void); extern PyTypeObject Py_ImBuf_Type; - -#endif /* __IMBUF_PY_API_H__ */ diff --git a/source/blender/python/generic/python_utildefines.h b/source/blender/python/generic/python_utildefines.h index 653122c9c33..1f093e633e4 100644 --- a/source/blender/python/generic/python_utildefines.h +++ b/source/blender/python/generic/python_utildefines.h @@ -20,8 +20,7 @@ * \note light addition to Python.h, use py_capi_utils.h for larger features. */ -#ifndef __PYTHON_UTILDEFINES_H__ -#define __PYTHON_UTILDEFINES_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -57,5 +56,3 @@ Py_LOCAL_INLINE(int) PyList_APPEND(PyObject *op, PyObject *v) #ifdef __cplusplus } #endif - -#endif /* __PYTHON_UTILDEFINES_H__ */ diff --git a/source/blender/python/gpu/gpu_py_api.h b/source/blender/python/gpu/gpu_py_api.h index e278bb63a49..2360bba1f5d 100644 --- a/source/blender/python/gpu/gpu_py_api.h +++ b/source/blender/python/gpu/gpu_py_api.h @@ -18,8 +18,7 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_API_H__ -#define __GPU_PY_API_H__ +#pragma once int bpygpu_ParsePrimType(PyObject *o, void *p); @@ -36,5 +35,3 @@ bool bpygpu_is_initialized_or_error(void); return -1; \ } \ ((void)0) - -#endif /* __GPU_PY_API_H__ */ diff --git a/source/blender/python/gpu/gpu_py_batch.h b/source/blender/python/gpu/gpu_py_batch.h index 1e916afcc2e..7c882eab8fc 100644 --- a/source/blender/python/gpu/gpu_py_batch.h +++ b/source/blender/python/gpu/gpu_py_batch.h @@ -18,8 +18,7 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_BATCH_H__ -#define __GPU_PY_BATCH_H__ +#pragma once #include "BLI_compiler_attrs.h" @@ -40,5 +39,3 @@ typedef struct BPyGPUBatch { } BPyGPUBatch; PyObject *BPyGPUBatch_CreatePyObject(struct GPUBatch *batch) ATTR_NONNULL(1); - -#endif /* __GPU_PY_BATCH_H__ */ diff --git a/source/blender/python/gpu/gpu_py_element.h b/source/blender/python/gpu/gpu_py_element.h index 055c9d54ecf..a8e22aae15a 100644 --- a/source/blender/python/gpu/gpu_py_element.h +++ b/source/blender/python/gpu/gpu_py_element.h @@ -18,8 +18,7 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_ELEMENT_H__ -#define __GPU_PY_ELEMENT_H__ +#pragma once extern PyTypeObject BPyGPUIndexBuf_Type; @@ -30,5 +29,3 @@ typedef struct BPyGPUIndexBuf { } BPyGPUIndexBuf; PyObject *BPyGPUIndexBuf_CreatePyObject(struct GPUIndexBuf *elem); - -#endif /* __GPU_PY_ELEMENT_H__ */ diff --git a/source/blender/python/gpu/gpu_py_matrix.h b/source/blender/python/gpu/gpu_py_matrix.h index cf187dee002..38a7f398b30 100644 --- a/source/blender/python/gpu/gpu_py_matrix.h +++ b/source/blender/python/gpu/gpu_py_matrix.h @@ -18,9 +18,6 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_MATRIX_H__ -#define __GPU_PY_MATRIX_H__ +#pragma once PyObject *BPyInit_gpu_matrix(void); - -#endif /* __GPU_PY_MATRIX_H__ */ diff --git a/source/blender/python/gpu/gpu_py_offscreen.h b/source/blender/python/gpu/gpu_py_offscreen.h index 61d7bd82abc..efe5b57b22e 100644 --- a/source/blender/python/gpu/gpu_py_offscreen.h +++ b/source/blender/python/gpu/gpu_py_offscreen.h @@ -18,8 +18,7 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_OFFSCREEN_H__ -#define __GPU_PY_OFFSCREEN_H__ +#pragma once #include "BLI_compiler_attrs.h" @@ -33,5 +32,3 @@ typedef struct BPyGPUOffScreen { } BPyGPUOffScreen; PyObject *BPyGPUOffScreen_CreatePyObject(struct GPUOffScreen *ofs) ATTR_NONNULL(1); - -#endif /* __GPU_PY_OFFSCREEN_H__ */ diff --git a/source/blender/python/gpu/gpu_py_select.h b/source/blender/python/gpu/gpu_py_select.h index 814b6028da1..857cd7bb7f8 100644 --- a/source/blender/python/gpu/gpu_py_select.h +++ b/source/blender/python/gpu/gpu_py_select.h @@ -18,9 +18,6 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_SELECT_H__ -#define __GPU_PY_SELECT_H__ +#pragma once PyObject *BPyInit_gpu_select(void); - -#endif /* __GPU_PY_SELECT_H__ */ diff --git a/source/blender/python/gpu/gpu_py_shader.h b/source/blender/python/gpu/gpu_py_shader.h index 92873753039..ee26c26acd4 100644 --- a/source/blender/python/gpu/gpu_py_shader.h +++ b/source/blender/python/gpu/gpu_py_shader.h @@ -18,8 +18,7 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_SHADER_H__ -#define __GPU_PY_SHADER_H__ +#pragma once extern PyTypeObject BPyGPUShader_Type; @@ -32,5 +31,3 @@ typedef struct BPyGPUShader { PyObject *BPyGPUShader_CreatePyObject(struct GPUShader *shader, bool is_builtin); PyObject *BPyInit_gpu_shader(void); - -#endif /* __GPU_PY_SHADER_H__ */ diff --git a/source/blender/python/gpu/gpu_py_types.h b/source/blender/python/gpu/gpu_py_types.h index d8048225604..56f73b8a504 100644 --- a/source/blender/python/gpu/gpu_py_types.h +++ b/source/blender/python/gpu/gpu_py_types.h @@ -18,8 +18,7 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_TYPES_H__ -#define __GPU_PY_TYPES_H__ +#pragma once #include "gpu_py_batch.h" #include "gpu_py_element.h" @@ -29,5 +28,3 @@ #include "gpu_py_vertex_format.h" PyObject *BPyInit_gpu_types(void); - -#endif /* __GPU_PY_TYPES_H__ */ diff --git a/source/blender/python/gpu/gpu_py_vertex_buffer.h b/source/blender/python/gpu/gpu_py_vertex_buffer.h index b7124d245a9..41791a35e6e 100644 --- a/source/blender/python/gpu/gpu_py_vertex_buffer.h +++ b/source/blender/python/gpu/gpu_py_vertex_buffer.h @@ -18,8 +18,7 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_VERTEX_BUFFER_H__ -#define __GPU_PY_VERTEX_BUFFER_H__ +#pragma once #include "BLI_compiler_attrs.h" @@ -34,5 +33,3 @@ typedef struct BPyGPUVertBuf { } BPyGPUVertBuf; PyObject *BPyGPUVertBuf_CreatePyObject(struct GPUVertBuf *vbo) ATTR_NONNULL(1); - -#endif /* __GPU_PY_VERTEX_BUFFER_H__ */ diff --git a/source/blender/python/gpu/gpu_py_vertex_format.h b/source/blender/python/gpu/gpu_py_vertex_format.h index 8ef466aa918..54d090e2923 100644 --- a/source/blender/python/gpu/gpu_py_vertex_format.h +++ b/source/blender/python/gpu/gpu_py_vertex_format.h @@ -18,8 +18,7 @@ * \ingroup bpygpu */ -#ifndef __GPU_PY_VERTEX_FORMAT_H__ -#define __GPU_PY_VERTEX_FORMAT_H__ +#pragma once #include "GPU_vertex_format.h" @@ -32,5 +31,3 @@ typedef struct BPyGPUVertFormat { } BPyGPUVertFormat; PyObject *BPyGPUVertFormat_CreatePyObject(struct GPUVertFormat *fmt); - -#endif /* __GPU_PY_VERTEX_FORMAT_H__ */ diff --git a/source/blender/python/intern/bpy.h b/source/blender/python/intern/bpy.h index 8f91c4e1208..744bf903443 100644 --- a/source/blender/python/intern/bpy.h +++ b/source/blender/python/intern/bpy.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_H__ -#define __BPY_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -38,5 +37,3 @@ extern struct CLG_LogRef *BPY_LOG_RNA; #ifdef __cplusplus } #endif - -#endif /* __BPY_H__ */ diff --git a/source/blender/python/intern/bpy_app.h b/source/blender/python/intern/bpy_app.h index 880686f3536..0e5b6747543 100644 --- a/source/blender/python/intern/bpy_app.h +++ b/source/blender/python/intern/bpy_app.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_H__ -#define __BPY_APP_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_H__ */ diff --git a/source/blender/python/intern/bpy_app_alembic.h b/source/blender/python/intern/bpy_app_alembic.h index fcd93fb2b13..4288b556172 100644 --- a/source/blender/python/intern/bpy_app_alembic.h +++ b/source/blender/python/intern/bpy_app_alembic.h @@ -21,8 +21,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_ALEMBIC_H__ -#define __BPY_APP_ALEMBIC_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -33,5 +32,3 @@ PyObject *BPY_app_alembic_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_ALEMBIC_H__ */ diff --git a/source/blender/python/intern/bpy_app_build_options.h b/source/blender/python/intern/bpy_app_build_options.h index a10f42d53be..390e3409fb8 100644 --- a/source/blender/python/intern/bpy_app_build_options.h +++ b/source/blender/python/intern/bpy_app_build_options.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_BUILD_OPTIONS_H__ -#define __BPY_APP_BUILD_OPTIONS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_build_options_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_BUILD_OPTIONS_H__ */ diff --git a/source/blender/python/intern/bpy_app_ffmpeg.h b/source/blender/python/intern/bpy_app_ffmpeg.h index 4809288662b..b189592e03e 100644 --- a/source/blender/python/intern/bpy_app_ffmpeg.h +++ b/source/blender/python/intern/bpy_app_ffmpeg.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_FFMPEG_H__ -#define __BPY_APP_FFMPEG_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_ffmpeg_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_FFMPEG_H__ */ diff --git a/source/blender/python/intern/bpy_app_handlers.h b/source/blender/python/intern/bpy_app_handlers.h index 9c9dd75dd18..eb8e85fc96e 100644 --- a/source/blender/python/intern/bpy_app_handlers.h +++ b/source/blender/python/intern/bpy_app_handlers.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_HANDLERS_H__ -#define __BPY_APP_HANDLERS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_handlers_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_HANDLERS_H__ */ diff --git a/source/blender/python/intern/bpy_app_icons.h b/source/blender/python/intern/bpy_app_icons.h index 2904dc06136..b0dcbe4b0ea 100644 --- a/source/blender/python/intern/bpy_app_icons.h +++ b/source/blender/python/intern/bpy_app_icons.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_ICONS_H__ -#define __BPY_APP_ICONS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_icons_module(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_ICONS_H__ */ diff --git a/source/blender/python/intern/bpy_app_ocio.h b/source/blender/python/intern/bpy_app_ocio.h index 145cea1a9be..bc4529a962c 100644 --- a/source/blender/python/intern/bpy_app_ocio.h +++ b/source/blender/python/intern/bpy_app_ocio.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_OCIO_H__ -#define __BPY_APP_OCIO_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_ocio_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_OCIO_H__ */ diff --git a/source/blender/python/intern/bpy_app_oiio.h b/source/blender/python/intern/bpy_app_oiio.h index e106a9a055a..47092899eec 100644 --- a/source/blender/python/intern/bpy_app_oiio.h +++ b/source/blender/python/intern/bpy_app_oiio.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_OIIO_H__ -#define __BPY_APP_OIIO_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_oiio_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_OIIO_H__ */ diff --git a/source/blender/python/intern/bpy_app_opensubdiv.h b/source/blender/python/intern/bpy_app_opensubdiv.h index f659e58c071..e18c827e6d8 100644 --- a/source/blender/python/intern/bpy_app_opensubdiv.h +++ b/source/blender/python/intern/bpy_app_opensubdiv.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_OPENSUBDIV_H__ -#define __BPY_APP_OPENSUBDIV_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_opensubdiv_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_OPENSUBDIV_H__ */ diff --git a/source/blender/python/intern/bpy_app_openvdb.h b/source/blender/python/intern/bpy_app_openvdb.h index 60c2bbaa922..ab73d561412 100644 --- a/source/blender/python/intern/bpy_app_openvdb.h +++ b/source/blender/python/intern/bpy_app_openvdb.h @@ -21,8 +21,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_OPENVDB_H__ -#define __BPY_APP_OPENVDB_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -33,5 +32,3 @@ PyObject *BPY_app_openvdb_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_OPENVDB_H__ */ diff --git a/source/blender/python/intern/bpy_app_sdl.h b/source/blender/python/intern/bpy_app_sdl.h index dd21ece89c7..b1d349c2a59 100644 --- a/source/blender/python/intern/bpy_app_sdl.h +++ b/source/blender/python/intern/bpy_app_sdl.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_SDL_H__ -#define __BPY_APP_SDL_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_sdl_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_SDL_H__ */ diff --git a/source/blender/python/intern/bpy_app_timers.h b/source/blender/python/intern/bpy_app_timers.h index 6da92eb8b31..9e62541c83a 100644 --- a/source/blender/python/intern/bpy_app_timers.h +++ b/source/blender/python/intern/bpy_app_timers.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_TIMERS_H__ -#define __BPY_APP_TIMERS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_app_timers_module(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_TIMERS_H__ */ diff --git a/source/blender/python/intern/bpy_app_translations.h b/source/blender/python/intern/bpy_app_translations.h index 1e98c7d9aaa..090cab5917c 100644 --- a/source/blender/python/intern/bpy_app_translations.h +++ b/source/blender/python/intern/bpy_app_translations.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_TRANSLATIONS_H__ -#define __BPY_APP_TRANSLATIONS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -31,5 +30,3 @@ void BPY_app_translations_end(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_TRANSLATIONS_H__ */ diff --git a/source/blender/python/intern/bpy_app_usd.h b/source/blender/python/intern/bpy_app_usd.h index 0482b10974d..2801408c2aa 100644 --- a/source/blender/python/intern/bpy_app_usd.h +++ b/source/blender/python/intern/bpy_app_usd.h @@ -21,8 +21,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_APP_USD_H__ -#define __BPY_APP_USD_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -33,5 +32,3 @@ PyObject *BPY_app_usd_struct(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_APP_USD_H__ */ diff --git a/source/blender/python/intern/bpy_capi_utils.h b/source/blender/python/intern/bpy_capi_utils.h index 46206f134ba..c021ec14933 100644 --- a/source/blender/python/intern/bpy_capi_utils.h +++ b/source/blender/python/intern/bpy_capi_utils.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_CAPI_UTILS_H__ -#define __BPY_CAPI_UTILS_H__ +#pragma once #if PY_VERSION_HEX < 0x03070000 # error "Python 3.7 or greater is required, you'll need to update your Python." @@ -57,5 +56,3 @@ extern void bpy_context_clear(struct bContext *C, const PyGILState_STATE *gilsta #ifdef __cplusplus } #endif - -#endif /* __BPY_CAPI_UTILS_H__ */ diff --git a/source/blender/python/intern/bpy_driver.h b/source/blender/python/intern/bpy_driver.h index 84f3cbdbbb3..d5064d9fa56 100644 --- a/source/blender/python/intern/bpy_driver.h +++ b/source/blender/python/intern/bpy_driver.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_DRIVER_H__ -#define __BPY_DRIVER_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -31,5 +30,3 @@ extern PyObject *bpy_pydriver_Dict; #ifdef __cplusplus } #endif - -#endif /* __BPY_DRIVER_H__ */ diff --git a/source/blender/python/intern/bpy_gizmo_wrap.h b/source/blender/python/intern/bpy_gizmo_wrap.h index 3a46dd5d78b..86b56ab2bd9 100644 --- a/source/blender/python/intern/bpy_gizmo_wrap.h +++ b/source/blender/python/intern/bpy_gizmo_wrap.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_GIZMO_WRAP_H__ -#define __BPY_GIZMO_WRAP_H__ +#pragma once struct wmGizmoGroupType; struct wmGizmoType; @@ -35,5 +34,3 @@ void BPY_RNA_gizmogroup_wrapper(struct wmGizmoGroupType *gzgt, void *userdata); #ifdef __cplusplus } #endif - -#endif /* __BPY_GIZMO_WRAP_H__ */ diff --git a/source/blender/python/intern/bpy_intern_string.h b/source/blender/python/intern/bpy_intern_string.h index f87a43e6bf6..0c75b723fb8 100644 --- a/source/blender/python/intern/bpy_intern_string.h +++ b/source/blender/python/intern/bpy_intern_string.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __BPY_INTERN_STRING_H__ -#define __BPY_INTERN_STRING_H__ +#pragma once /** \file * \ingroup pythonintern @@ -48,5 +47,3 @@ extern PyObject *bpy_intern_str_unregister; #ifdef __cplusplus } #endif - -#endif /* __BPY_INTERN_STRING_H__ */ diff --git a/source/blender/python/intern/bpy_library.h b/source/blender/python/intern/bpy_library.h index aca4ae94d6e..fbcf111e37d 100644 --- a/source/blender/python/intern/bpy_library.h +++ b/source/blender/python/intern/bpy_library.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_LIBRARY_H__ -#define __BPY_LIBRARY_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -33,5 +32,3 @@ extern PyMethodDef BPY_library_write_method_def; #ifdef __cplusplus } #endif - -#endif /* __BPY_LIBRARY_H__ */ diff --git a/source/blender/python/intern/bpy_msgbus.h b/source/blender/python/intern/bpy_msgbus.h index 9a797218832..8d4846fd707 100644 --- a/source/blender/python/intern/bpy_msgbus.h +++ b/source/blender/python/intern/bpy_msgbus.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_MSGBUS_H__ -#define __BPY_MSGBUS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_msgbus_module(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_MSGBUS_H__ */ diff --git a/source/blender/python/intern/bpy_operator.h b/source/blender/python/intern/bpy_operator.h index 37a6acfe822..3cb335d5d9a 100644 --- a/source/blender/python/intern/bpy_operator.h +++ b/source/blender/python/intern/bpy_operator.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_OPERATOR_H__ -#define __BPY_OPERATOR_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -38,5 +37,3 @@ PyObject *BPY_operator_module(void); #ifdef __cplusplus } #endif - -#endif diff --git a/source/blender/python/intern/bpy_operator_wrap.h b/source/blender/python/intern/bpy_operator_wrap.h index 942f9dbea39..9e496cd8d26 100644 --- a/source/blender/python/intern/bpy_operator_wrap.h +++ b/source/blender/python/intern/bpy_operator_wrap.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_OPERATOR_WRAP_H__ -#define __BPY_OPERATOR_WRAP_H__ +#pragma once struct wmOperatorType; @@ -37,5 +36,3 @@ void BPY_RNA_operator_macro_wrapper(struct wmOperatorType *ot, void *userdata); #ifdef __cplusplus } #endif - -#endif diff --git a/source/blender/python/intern/bpy_path.h b/source/blender/python/intern/bpy_path.h index 0da9e610b53..3e25cb26288 100644 --- a/source/blender/python/intern/bpy_path.h +++ b/source/blender/python/intern/bpy_path.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_PATH_H__ -#define __BPY_PATH_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPyInit__bpy_path(void); #ifdef __cplusplus } #endif - -#endif diff --git a/source/blender/python/intern/bpy_props.h b/source/blender/python/intern/bpy_props.h index 9bcfe8e263a..3d7860dcdd8 100644 --- a/source/blender/python/intern/bpy_props.h +++ b/source/blender/python/intern/bpy_props.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_PROPS_H__ -#define __BPY_PROPS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -36,5 +35,3 @@ StructRNA *pointer_type_from_py(PyObject *value, const char *error_prefix); #ifdef __cplusplus } #endif - -#endif diff --git a/source/blender/python/intern/bpy_rna.h b/source/blender/python/intern/bpy_rna.h index fadda9a8002..a2c2171d151 100644 --- a/source/blender/python/intern/bpy_rna.h +++ b/source/blender/python/intern/bpy_rna.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_RNA_H__ -#define __BPY_RNA_H__ +#pragma once /* --- bpy build options --- */ #ifdef WITH_PYTHON_SAFETY @@ -272,5 +271,3 @@ extern BPy_StructRNA *bpy_context_module; #ifdef __cplusplus } #endif - -#endif diff --git a/source/blender/python/intern/bpy_rna_anim.h b/source/blender/python/intern/bpy_rna_anim.h index 88537778dde..7c840e616b1 100644 --- a/source/blender/python/intern/bpy_rna_anim.h +++ b/source/blender/python/intern/bpy_rna_anim.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __BPY_RNA_ANIM_H__ -#define __BPY_RNA_ANIM_H__ +#pragma once /** \file * \ingroup pythonintern @@ -38,5 +37,3 @@ PyObject *pyrna_struct_driver_remove(BPy_StructRNA *self, PyObject *args); #ifdef __cplusplus } #endif - -#endif /* __BPY_RNA_ANIM_H__ */ diff --git a/source/blender/python/intern/bpy_rna_callback.h b/source/blender/python/intern/bpy_rna_callback.h index 67392b60995..ae42c4cb1a4 100644 --- a/source/blender/python/intern/bpy_rna_callback.h +++ b/source/blender/python/intern/bpy_rna_callback.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __BPY_RNA_CALLBACK_H__ -#define __BPY_RNA_CALLBACK_H__ +#pragma once /** \file * \ingroup pythonintern @@ -39,5 +38,3 @@ PyObject *pyrna_callback_classmethod_remove(PyObject *cls, PyObject *args); #ifdef __cplusplus } #endif - -#endif /* __BPY_RNA_CALLBACK_H__ */ diff --git a/source/blender/python/intern/bpy_rna_driver.h b/source/blender/python/intern/bpy_rna_driver.h index a534f770732..cc2c4550870 100644 --- a/source/blender/python/intern/bpy_rna_driver.h +++ b/source/blender/python/intern/bpy_rna_driver.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __BPY_RNA_DRIVER_H__ -#define __BPY_RNA_DRIVER_H__ +#pragma once /** \file * \ingroup pythonintern @@ -38,5 +37,3 @@ bool pyrna_driver_is_equal_anim_rna(const struct PathResolvedRNA *anim_rna, #ifdef __cplusplus } #endif - -#endif /* __BPY_RNA_DRIVER_H__ */ diff --git a/source/blender/python/intern/bpy_rna_gizmo.h b/source/blender/python/intern/bpy_rna_gizmo.h index b209dbf4a26..307b694338c 100644 --- a/source/blender/python/intern/bpy_rna_gizmo.h +++ b/source/blender/python/intern/bpy_rna_gizmo.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_RNA_GIZMO_H__ -#define __BPY_RNA_GIZMO_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ int BPY_rna_gizmo_module(PyObject *); #ifdef __cplusplus } #endif - -#endif /* __BPY_RNA_GIZMO_H__ */ diff --git a/source/blender/python/intern/bpy_rna_id_collection.h b/source/blender/python/intern/bpy_rna_id_collection.h index 223ae126323..320a9e66ff8 100644 --- a/source/blender/python/intern/bpy_rna_id_collection.h +++ b/source/blender/python/intern/bpy_rna_id_collection.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_RNA_ID_COLLECTION_H__ -#define __BPY_RNA_ID_COLLECTION_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -32,5 +31,3 @@ extern PyMethodDef BPY_rna_id_collection_orphans_purge_method_def; #ifdef __cplusplus } #endif - -#endif /* __BPY_RNA_ID_COLLECTION_H__ */ diff --git a/source/blender/python/intern/bpy_rna_types_capi.h b/source/blender/python/intern/bpy_rna_types_capi.h index 402dc2c7936..eb8dd14d888 100644 --- a/source/blender/python/intern/bpy_rna_types_capi.h +++ b/source/blender/python/intern/bpy_rna_types_capi.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_RNA_TYPES_CAPI_H__ -#define __BPY_RNA_TYPES_CAPI_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ void BPY_rna_types_extend_capi(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_RNA_TYPES_CAPI_H__ */ diff --git a/source/blender/python/intern/bpy_traceback.h b/source/blender/python/intern/bpy_traceback.h index cb23dd23c9b..26f6a574439 100644 --- a/source/blender/python/intern/bpy_traceback.h +++ b/source/blender/python/intern/bpy_traceback.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_TRACEBACK_H__ -#define __BPY_TRACEBACK_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ void python_script_error_jump(const char *filepath, int *lineno, int *offset); #ifdef __cplusplus } #endif - -#endif /* __BPY_TRACEBACK_H__ */ diff --git a/source/blender/python/intern/bpy_utils_previews.h b/source/blender/python/intern/bpy_utils_previews.h index 23fd0216668..dbe74f619a9 100644 --- a/source/blender/python/intern/bpy_utils_previews.h +++ b/source/blender/python/intern/bpy_utils_previews.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_UTILS_PREVIEWS_H__ -#define __BPY_UTILS_PREVIEWS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_utils_previews_module(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_UTILS_PREVIEWS_H__ */ diff --git a/source/blender/python/intern/bpy_utils_units.h b/source/blender/python/intern/bpy_utils_units.h index add766d0d93..7a135bc6163 100644 --- a/source/blender/python/intern/bpy_utils_units.h +++ b/source/blender/python/intern/bpy_utils_units.h @@ -18,8 +18,7 @@ * \ingroup pythonintern */ -#ifndef __BPY_UTILS_UNITS_H__ -#define __BPY_UTILS_UNITS_H__ +#pragma once #ifdef __cplusplus extern "C" { @@ -30,5 +29,3 @@ PyObject *BPY_utils_units(void); #ifdef __cplusplus } #endif - -#endif /* __BPY_UTILS_UNITS_H__ */ diff --git a/source/blender/python/mathutils/mathutils.h b/source/blender/python/mathutils/mathutils.h index c59fa75b651..d8d390cfad0 100644 --- a/source/blender/python/mathutils/mathutils.h +++ b/source/blender/python/mathutils/mathutils.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __MATHUTILS_H__ -#define __MATHUTILS_H__ +#pragma once /** \file * \ingroup pymathutils @@ -195,5 +194,3 @@ int column_vector_multiplication(float rvec[4], VectorObject *vec, MatrixObject /* dynstr as python string utility functions */ PyObject *mathutils_dynstr_to_py(struct DynStr *ds); #endif - -#endif /* __MATHUTILS_H__ */ diff --git a/source/blender/python/mathutils/mathutils_Color.h b/source/blender/python/mathutils/mathutils_Color.h index 51e1746ae74..c966bf1e3b2 100644 --- a/source/blender/python/mathutils/mathutils_Color.h +++ b/source/blender/python/mathutils/mathutils_Color.h @@ -18,8 +18,7 @@ * \ingroup pymathutils */ -#ifndef __MATHUTILS_COLOR_H__ -#define __MATHUTILS_COLOR_H__ +#pragma once extern PyTypeObject color_Type; #define ColorObject_Check(v) PyObject_TypeCheck((v), &color_Type) @@ -42,5 +41,3 @@ PyObject *Color_CreatePyObject_wrap(float col[3], PyTypeObject *base_type) ATTR_ PyObject *Color_CreatePyObject_cb(PyObject *cb_user, unsigned char cb_type, unsigned char cb_subtype) ATTR_WARN_UNUSED_RESULT; - -#endif /* __MATHUTILS_COLOR_H__ */ diff --git a/source/blender/python/mathutils/mathutils_Euler.h b/source/blender/python/mathutils/mathutils_Euler.h index c56962395e5..0deef3cfdf3 100644 --- a/source/blender/python/mathutils/mathutils_Euler.h +++ b/source/blender/python/mathutils/mathutils_Euler.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __MATHUTILS_EULER_H__ -#define __MATHUTILS_EULER_H__ +#pragma once /** \file * \ingroup pymathutils @@ -50,5 +49,3 @@ PyObject *Euler_CreatePyObject_cb(PyObject *cb_user, unsigned char cb_subtype) ATTR_WARN_UNUSED_RESULT; short euler_order_from_string(const char *str, const char *error_prefix); - -#endif /* __MATHUTILS_EULER_H__ */ diff --git a/source/blender/python/mathutils/mathutils_Matrix.h b/source/blender/python/mathutils/mathutils_Matrix.h index a0e2256b1ce..588c0b94891 100644 --- a/source/blender/python/mathutils/mathutils_Matrix.h +++ b/source/blender/python/mathutils/mathutils_Matrix.h @@ -18,8 +18,7 @@ * \ingroup pymathutils */ -#ifndef __MATHUTILS_MATRIX_H__ -#define __MATHUTILS_MATRIX_H__ +#pragma once extern PyTypeObject matrix_Type; extern PyTypeObject matrix_access_Type; @@ -96,5 +95,3 @@ extern struct Mathutils_Callback mathutils_matrix_col_cb; extern struct Mathutils_Callback mathutils_matrix_translation_cb; void matrix_as_3x3(float mat[3][3], MatrixObject *self); - -#endif /* __MATHUTILS_MATRIX_H__ */ diff --git a/source/blender/python/mathutils/mathutils_Quaternion.h b/source/blender/python/mathutils/mathutils_Quaternion.h index bc6bd307ece..7d20558939e 100644 --- a/source/blender/python/mathutils/mathutils_Quaternion.h +++ b/source/blender/python/mathutils/mathutils_Quaternion.h @@ -14,8 +14,7 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __MATHUTILS_QUATERNION_H__ -#define __MATHUTILS_QUATERNION_H__ +#pragma once /** \file * \ingroup pymathutils @@ -44,5 +43,3 @@ PyObject *Quaternion_CreatePyObject_wrap(float quat[4], PyObject *Quaternion_CreatePyObject_cb(PyObject *cb_user, unsigned char cb_type, unsigned char cb_subtype) ATTR_WARN_UNUSED_RESULT; - -#endif /* __MATHUTILS_QUATERNION_H__ */ diff --git a/source/blender/python/mathutils/mathutils_Vector.h b/source/blender/python/mathutils/mathutils_Vector.h index f75702bc54c..09fc429f9cc 100644 --- a/source/blender/python/mathutils/mathutils_Vector.h +++ b/source/blender/python/mathutils/mathutils_Vector.h @@ -18,8 +18,7 @@ * \ingroup pymathutils */ -#ifndef __MATHUTILS_VECTOR_H__ -#define __MATHUTILS_VECTOR_H__ +#pragma once extern PyTypeObject vector_Type; @@ -48,5 +47,3 @@ PyObject *Vector_CreatePyObject_alloc(float *vec, const int size, PyTypeObject *base_type) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1); - -#endif /* __MATHUTILS_VECTOR_H__ */ diff --git a/source/blender/python/mathutils/mathutils_bvhtree.h b/source/blender/python/mathutils/mathutils_bvhtree.h index 2991982f3a2..82b09f11e5e 100644 --- a/source/blender/python/mathutils/mathutils_bvhtree.h +++ b/source/blender/python/mathutils/mathutils_bvhtree.h @@ -18,8 +18,7 @@ * \ingroup mathutils */ -#ifndef __MATHUTILS_BVHTREE_H__ -#define __MATHUTILS_BVHTREE_H__ +#pragma once PyMODINIT_FUNC PyInit_mathutils_bvhtree(void); @@ -27,5 +26,3 @@ extern PyTypeObject PyBVHTree_Type; #define PyBVHTree_Check(v) PyObject_TypeCheck((v), &PyBVHTree_Type) #define PyBVHTree_CheckExact(v) (Py_TYPE(v) == &PyBVHTree_Type) - -#endif /* __MATHUTILS_BVHTREE_H__ */ diff --git a/source/blender/python/mathutils/mathutils_geometry.h b/source/blender/python/mathutils/mathutils_geometry.h index 5a1198b4a26..4a200ec98ca 100644 --- a/source/blender/python/mathutils/mathutils_geometry.h +++ b/source/blender/python/mathutils/mathutils_geometry.h @@ -14,13 +14,10 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __MATHUTILS_GEOMETRY_H__ -#define __MATHUTILS_GEOMETRY_H__ +#pragma once /** \file * \ingroup pymathutils */ PyMODINIT_FUNC PyInit_mathutils_geometry(void); - -#endif /* __MATHUTILS_GEOMETRY_H__ */ diff --git a/source/blender/python/mathutils/mathutils_interpolate.h b/source/blender/python/mathutils/mathutils_interpolate.h index 50dee1ee8de..c51d2b6905b 100644 --- a/source/blender/python/mathutils/mathutils_interpolate.h +++ b/source/blender/python/mathutils/mathutils_interpolate.h @@ -14,13 +14,10 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef __MATHUTILS_INTERPOLATE_H__ -#define __MATHUTILS_INTERPOLATE_H__ +#pragma once /** \file * \ingroup pymathutils */ PyMODINIT_FUNC PyInit_mathutils_interpolate(void); - -#endif /* __MATHUTILS_INTERPOLATE_H__ */ diff --git a/source/blender/python/mathutils/mathutils_kdtree.h b/source/blender/python/mathutils/mathutils_kdtree.h index 99411997282..3df3fc8d382 100644 --- a/source/blender/python/mathutils/mathutils_kdtree.h +++ b/source/blender/python/mathutils/mathutils_kdtree.h @@ -18,11 +18,8 @@ * \ingroup mathutils */ -#ifndef __MATHUTILS_KDTREE_H__ -#define __MATHUTILS_KDTREE_H__ +#pragma once PyMODINIT_FUNC PyInit_mathutils_kdtree(void); extern PyTypeObject PyKDTree_Type; - -#endif /* __MATHUTILS_KDTREE_H__ */ diff --git a/source/blender/python/mathutils/mathutils_noise.h b/source/blender/python/mathutils/mathutils_noise.h index 8204c084947..da5e1a99a03 100644 --- a/source/blender/python/mathutils/mathutils_noise.h +++ b/source/blender/python/mathutils/mathutils_noise.h @@ -18,9 +18,6 @@ * \ingroup mathutils */ -#ifndef __MATHUTILS_NOISE_H__ -#define __MATHUTILS_NOISE_H__ +#pragma once PyMODINIT_FUNC PyInit_mathutils_noise(void); - -#endif /* __MATHUTILS_NOISE_H__ */ -- cgit v1.2.3