diff options
author | Campbell Barton <campbell@blender.org> | 2022-04-06 02:40:11 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-04-06 02:40:11 +0300 |
commit | 20bb859d9be1bcb5c4b04d2be8df25db6f8e712b (patch) | |
tree | 60ac684052dc4919168888645605c0a033b4dacd /source/blender/blenkernel | |
parent | 931ae424b9ef09b446d9584df51d27ac2a137cf2 (diff) |
Cleanup: quiet compiler warnings
Ideally this wouldn't be needed, I couldn't find a good solution
to avoid casting when comparing const/non-const pointers in this case.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/attribute.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/attribute.c b/source/blender/blenkernel/intern/attribute.c index 13c896fd1ab..c3d4eb72c0d 100644 --- a/source/blender/blenkernel/intern/attribute.c +++ b/source/blender/blenkernel/intern/attribute.c @@ -93,7 +93,7 @@ static CustomData *attribute_customdata_find(ID *id, CustomDataLayer *layer) for (AttributeDomain domain = 0; domain < ATTR_DOMAIN_NUM; domain++) { CustomData *customdata = info[domain].customdata; if (customdata && - ARRAY_HAS_ITEM(layer, (CustomDataLayer const *)customdata->layers, customdata->totlayer)) { + ARRAY_HAS_ITEM((CustomDataLayer *)layer, customdata->layers, customdata->totlayer)) { return customdata; } } @@ -299,7 +299,8 @@ AttributeDomain BKE_id_attribute_domain(ID *id, const CustomDataLayer *layer) for (AttributeDomain domain = 0; domain < ATTR_DOMAIN_NUM; domain++) { CustomData *customdata = info[domain].customdata; - if (customdata && ARRAY_HAS_ITEM(layer, customdata->layers, customdata->totlayer)) { + if (customdata && + ARRAY_HAS_ITEM((CustomDataLayer *)layer, customdata->layers, customdata->totlayer)) { return domain; } } @@ -315,7 +316,8 @@ int BKE_id_attribute_data_length(ID *id, CustomDataLayer *layer) for (AttributeDomain domain = 0; domain < ATTR_DOMAIN_NUM; domain++) { CustomData *customdata = info[domain].customdata; - if (customdata && ARRAY_HAS_ITEM(layer, customdata->layers, customdata->totlayer)) { + if (customdata && + ARRAY_HAS_ITEM((CustomDataLayer *)layer, customdata->layers, customdata->totlayer)) { return info[domain].length; } } |