diff options
author | Campbell Barton <campbell@blender.org> | 2022-09-25 10:04:52 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-09-25 11:26:27 +0300 |
commit | 891949cbb47143420f4324cb60efc05ef5d70b39 (patch) | |
tree | fe70a45612ae96f9ce1f37378ef5ff035d3127f5 /source/blender/makesdna | |
parent | c9e35c2ced92082c86f1ecb9ecd16c6230218c7c (diff) |
Cleanup: use 'u' prefixed integer types for brevity & cast style
To use function style cast '(unsigned char)x' can't be replaced by
'unsigned char(x)'.
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r-- | source/blender/makesdna/intern/dna_genfile.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/makesdna/intern/dna_genfile.c b/source/blender/makesdna/intern/dna_genfile.c index 1b424756b0a..42df7912e3a 100644 --- a/source/blender/makesdna/intern/dna_genfile.c +++ b/source/blender/makesdna/intern/dna_genfile.c @@ -210,7 +210,7 @@ static int dna_struct_find_nr_ex_impl( #endif /* Regular args. */ const char *str, - unsigned int *index_last) + uint *index_last) { if (*index_last < structs_len) { const SDNA_Struct *struct_info = structs[*index_last]; @@ -242,7 +242,7 @@ static int dna_struct_find_nr_ex_impl( return -1; } -int DNA_struct_find_nr_ex(const SDNA *sdna, const char *str, unsigned int *index_last) +int DNA_struct_find_nr_ex(const SDNA *sdna, const char *str, uint *index_last) { return dna_struct_find_nr_ex_impl( /* Expand SDNA. */ @@ -258,7 +258,7 @@ int DNA_struct_find_nr_ex(const SDNA *sdna, const char *str, unsigned int *index index_last); } -int DNA_struct_alias_find_nr_ex(const SDNA *sdna, const char *str, unsigned int *index_last) +int DNA_struct_alias_find_nr_ex(const SDNA *sdna, const char *str, uint *index_last) { #ifdef WITH_DNA_GHASH BLI_assert(sdna->alias.structs_map != NULL); @@ -279,13 +279,13 @@ int DNA_struct_alias_find_nr_ex(const SDNA *sdna, const char *str, unsigned int int DNA_struct_find_nr(const SDNA *sdna, const char *str) { - unsigned int index_last_dummy = UINT_MAX; + uint index_last_dummy = UINT_MAX; return DNA_struct_find_nr_ex(sdna, str, &index_last_dummy); } int DNA_struct_alias_find_nr(const SDNA *sdna, const char *str) { - unsigned int index_last_dummy = UINT_MAX; + uint index_last_dummy = UINT_MAX; return DNA_struct_alias_find_nr_ex(sdna, str, &index_last_dummy); } @@ -741,7 +741,7 @@ static void cast_primitive_type(const eSDNA_Type old_type, break; } case SDNA_TYPE_USHORT: { - const ushort value = *((unsigned short *)old_data); + const ushort value = *((ushort *)old_data); old_value_i = value; old_value_f = (double)value; break; |