diff options
Diffstat (limited to 'source/blender/bmesh/intern/bmesh_operators.c')
-rw-r--r-- | source/blender/bmesh/intern/bmesh_operators.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/bmesh/intern/bmesh_operators.c b/source/blender/bmesh/intern/bmesh_operators.c index c5e030c436a..c2421939aa8 100644 --- a/source/blender/bmesh/intern/bmesh_operators.c +++ b/source/blender/bmesh/intern/bmesh_operators.c @@ -963,7 +963,7 @@ void BMO_slot_buffer_from_single(BMOperator *op, BMOpSlot *slot, BMHeader *ele) BMO_ASSERT_SLOT_IN_OP(slot, op); BLI_assert(slot->slot_type == BMO_OP_SLOT_ELEMENT_BUF); BLI_assert(slot->slot_subtype.elem & BMO_OP_SLOT_SUBTYPE_ELEM_IS_SINGLE); - BLI_assert(slot->len == 0 || slot->len == 1); + BLI_assert(ELEM(slot->len, 0, 1)); BLI_assert(slot->slot_subtype.elem & ele->htype); @@ -979,7 +979,7 @@ void BMO_slot_buffer_from_array(BMOperator *op, { BMO_ASSERT_SLOT_IN_OP(slot, op); BLI_assert(slot->slot_type == BMO_OP_SLOT_ELEMENT_BUF); - BLI_assert(slot->len == 0 || slot->len == ele_buffer_len); + BLI_assert(ELEM(slot->len, 0, ele_buffer_len)); if (slot->data.buf == NULL) { slot->data.buf = BLI_memarena_alloc(op->arena, sizeof(*slot->data.buf) * ele_buffer_len); @@ -993,7 +993,7 @@ void *BMO_slot_buffer_get_single(BMOpSlot *slot) { BLI_assert(slot->slot_type == BMO_OP_SLOT_ELEMENT_BUF); BLI_assert(slot->slot_subtype.elem & BMO_OP_SLOT_SUBTYPE_ELEM_IS_SINGLE); - BLI_assert(slot->len == 0 || slot->len == 1); + BLI_assert(ELEM(slot->len, 0, 1)); return slot->len ? (BMHeader *)slot->data.buf[0] : NULL; } |