From c2751f8a11fa6bd37b2c092ce8f893bc843bfe1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sybren=20A=2E=20St=C3=BCvel?= Date: Mon, 25 Apr 2022 16:00:09 +0200 Subject: Cleanup: fix unused variable warning in `paint_vertex.cc` No functional changes. --- source/blender/editors/sculpt_paint/paint_vertex.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'source/blender/editors') diff --git a/source/blender/editors/sculpt_paint/paint_vertex.cc b/source/blender/editors/sculpt_paint/paint_vertex.cc index 8b62dd33961..58e45f360d6 100644 --- a/source/blender/editors/sculpt_paint/paint_vertex.cc +++ b/source/blender/editors/sculpt_paint/paint_vertex.cc @@ -3396,18 +3396,17 @@ static void do_vpaint_brush_smear(bContext *C, * paint each loop belonging to this vert. */ for (int j = 0; j < gmap->vert_to_poly[v_index].count; j++) { const int p_index = gmap->vert_to_poly[v_index].indices[j]; - const int l_index = gmap->vert_to_loop[v_index].indices[j]; int elem_index; if constexpr (domain == ATTR_DOMAIN_POINT) { elem_index = v_index; } else { + const int l_index = gmap->vert_to_loop[v_index].indices[j]; elem_index = l_index; + BLI_assert(me->mloop[l_index].v == v_index); } - BLI_assert(me->mloop[l_index].v == v_index); - const MPoly *mp = &me->mpoly[p_index]; if (!use_face_sel || mp->flag & ME_FACE_SEL) { /* Get the previous element color */ -- cgit v1.2.3