Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2019-02-27 07:07:50 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-02-27 07:09:48 +0300
commit6a03199b50e02d57a50eb24441ef7be0b7e965ac (patch)
treea5e5374cb81742d2c2df05ecf315afaafcaf3d0e /source/blender/makesdna/DNA_ID.h
parentea69d9858058e027a8b49d0cf313c8d4abb777a4 (diff)
Cleanup: use '_pad' convention for padding in all DNA structs
Avoids mixing these in with regular variables in code-completion. Use char for pad members except for 'void *', to make size clearer. Removed/shrink a few redundant padding vars which were >= 8 bytes.
Diffstat (limited to 'source/blender/makesdna/DNA_ID.h')
-rw-r--r--source/blender/makesdna/DNA_ID.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/makesdna/DNA_ID.h b/source/blender/makesdna/DNA_ID.h
index 1d9518f657e..fa519ec8011 100644
--- a/source/blender/makesdna/DNA_ID.h
+++ b/source/blender/makesdna/DNA_ID.h
@@ -73,7 +73,7 @@ typedef struct IDProperty {
char name[64];
/* saved is used to indicate if this struct has been saved yet.
- * seemed like a good idea as a pad var was needed anyway :) */
+ * seemed like a good idea as a '_pad' var was needed anyway :) */
int saved;
/** Note, alignment for 64 bits. */
IDPropertyData data;
@@ -145,7 +145,7 @@ typedef struct IDOverrideStaticPropertyOperation {
/* Type of override. */
short operation;
short flag;
- short pad_s1[2];
+ char _pad0[4];
/* Sub-item references, if needed (for arrays or collections only).
* We need both reference and local values to allow e.g. insertion into collections (constraints, modifiers...).
@@ -208,7 +208,7 @@ typedef struct IDOverrideStatic {
ListBase properties;
short flag;
- short pad[3];
+ char _pad[6];
/* Read/write data. */
/* Temp ID storing extra override data (used for differential operations only currently).
@@ -249,7 +249,7 @@ typedef struct ID {
int us;
int icon_id;
int recalc;
- int pad;
+ char _pad[4];
IDProperty *properties;
/** Reference linked ID which this one overrides. */
@@ -329,7 +329,7 @@ typedef struct PreviewImage {
/** Runtime data. */
short tag;
- char pad[2];
+ char _pad[2];
} PreviewImage;
#define PRV_DEFERRED_DATA(prv) \