diff options
author | Campbell Barton <campbell@blender.org> | 2022-09-25 11:33:28 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-09-25 13:17:08 +0300 |
commit | f68cfd6bb078482c4a779a6e26a56e2734edb5b8 (patch) | |
tree | 2878e5b80dba5bdeba186d99661d604eb38879cd /source/blender/blenkernel/intern/attribute.cc | |
parent | c7b247a118e302a3afc6473797e53b6af28b69e2 (diff) |
Cleanup: replace C-style casts with functional casts for numeric types
Diffstat (limited to 'source/blender/blenkernel/intern/attribute.cc')
-rw-r--r-- | source/blender/blenkernel/intern/attribute.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/attribute.cc b/source/blender/blenkernel/intern/attribute.cc index c69a7b4b2c7..1a54454bf9a 100644 --- a/source/blender/blenkernel/intern/attribute.cc +++ b/source/blender/blenkernel/intern/attribute.cc @@ -354,7 +354,7 @@ CustomDataLayer *BKE_id_attribute_search(ID *id, get_domains(id, info); for (eAttrDomain domain = ATTR_DOMAIN_POINT; domain < ATTR_DOMAIN_NUM; - domain = static_cast<eAttrDomain>((int(domain)) + 1)) { + domain = static_cast<eAttrDomain>(int(domain) + 1)) { if (!(domain_mask & ATTR_DOMAIN_AS_MASK(domain))) { continue; } @@ -388,7 +388,7 @@ int BKE_id_attributes_length(const ID *id, eAttrDomainMask domain_mask, eCustomD continue; } - if ((1 << (int)domain) & domain_mask) { + if ((1 << int(domain)) & domain_mask) { length += CustomData_number_of_layers_typemask(customdata, mask); } } @@ -574,7 +574,7 @@ CustomDataLayer *BKE_id_attribute_from_index(ID *id, for (const int domain : IndexRange(ATTR_DOMAIN_NUM)) { CustomData *customdata = info[domain].customdata; - if (!customdata || !((1 << (int)domain) & domain_mask)) { + if (!customdata || !((1 << int(domain)) & domain_mask)) { continue; } |