Cleanup: warnings
Quiet extra-semi-stmt & missing-variable-declarations
This commit is contained in:
@@ -585,7 +585,7 @@ static bool data_transfer_layersmapping_cdlayers_multisrc_to_dst(ListBase *r_map
|
||||
|
||||
/* Find last source actually used! */
|
||||
while (idx_src-- && !use_layers_src[idx_src]) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
idx_src++;
|
||||
|
||||
|
||||
@@ -1124,7 +1124,7 @@ static bool data_transfer_layersmapping_vgroups_multisrc_to_dst(ListBase *r_map,
|
||||
/* Find last source actually used! */
|
||||
idx_src = num_layers_src;
|
||||
while (idx_src-- && !use_layers_src[idx_src]) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
idx_src++;
|
||||
|
||||
|
||||
@@ -5393,7 +5393,7 @@ static void dynamic_paint_effect_drip_cb(void *__restrict userdata,
|
||||
const uint8_t epointlock_bitmask = 1 << (n_trgt & 7); /* 7 == 0b111 */
|
||||
while (atomic_fetch_and_or_uint8(&point_locks[epointlock_idx], epointlock_bitmask) &
|
||||
epointlock_bitmask) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
PaintPoint *ePoint = &((PaintPoint *)sData->type_data)[n_trgt];
|
||||
@@ -5440,7 +5440,7 @@ static void dynamic_paint_effect_drip_cb(void *__restrict userdata,
|
||||
const uint8_t ppointlock_bitmask = 1 << (index & 7); /* 7 == 0b111 */
|
||||
while (atomic_fetch_and_or_uint8(&point_locks[ppointlock_idx], ppointlock_bitmask) &
|
||||
ppointlock_bitmask) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
pPoint->wetness -= ppoint_wetness_diff;
|
||||
|
||||
@@ -81,7 +81,7 @@ IDOverrideStatic *BKE_override_static_init(ID *local_id, ID *reference_id)
|
||||
for (ancestor_id = reference_id; ancestor_id != NULL && ancestor_id->override_static != NULL &&
|
||||
ancestor_id->override_static->reference != NULL;
|
||||
ancestor_id = ancestor_id->override_static->reference) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
if (ancestor_id != NULL && ancestor_id->override_static != NULL) {
|
||||
|
||||
@@ -1170,7 +1170,7 @@ static int psys_thread_context_init_distribute(ParticleThreadContext *ctx,
|
||||
int i_mapped = 0;
|
||||
|
||||
for (i = 0; i < totelem && element_weight[i] == 0.0f; i++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
element_sum[i_mapped] = element_weight[i] * inv_totweight;
|
||||
element_map[i_mapped] = i;
|
||||
@@ -1216,7 +1216,7 @@ static int psys_thread_context_init_distribute(ParticleThreadContext *ctx,
|
||||
|
||||
for (i = 0, p = 0; p < totpart; p++, pos += step) {
|
||||
for (; (i < totmapped - 1) && (pos > (double)element_sum[i]); i++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
particle_element[p] = element_map[i];
|
||||
|
||||
@@ -181,10 +181,10 @@ static int partition_indices(int *prim_indices, int lo, int hi, int axis, float
|
||||
int i = lo, j = hi;
|
||||
for (;;) {
|
||||
for (; prim_bbc[prim_indices[i]].bcentroid[axis] < mid; i++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
for (; mid < prim_bbc[prim_indices[j]].bcentroid[axis]; j--) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
if (!(i < j)) {
|
||||
@@ -216,18 +216,18 @@ static int partition_indices_material(PBVH *bvh, int lo, int hi)
|
||||
for (;;) {
|
||||
if (bvh->looptri) {
|
||||
for (; face_materials_match(first, &mpoly[looptri[indices[i]].poly]); i++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
for (; !face_materials_match(first, &mpoly[looptri[indices[j]].poly]); j--) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
}
|
||||
else {
|
||||
for (; grid_materials_match(first, &flagmats[indices[i]]); i++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
for (; !grid_materials_match(first, &flagmats[indices[j]]); j--) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -275,10 +275,10 @@ static int search_closest_marker_index(MovieTrackingTrack *track, int ref_frame)
|
||||
i = MAX2(0, i);
|
||||
i = MIN2(i, end - 1);
|
||||
for (; i < end - 1 && markers[i].framenr <= ref_frame; ++i) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
for (; 0 < i && markers[i].framenr > ref_frame; --i) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
track->last_marker = i;
|
||||
|
||||
@@ -663,7 +663,7 @@ static const char *unit_find_str(const char *str, const char *substr, bool case_
|
||||
}
|
||||
/* If str_found is not a valid unit, we have to check further in the string... */
|
||||
for (str_found++; isalpha_or_utf8(*str_found); str_found++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
str = str_found;
|
||||
}
|
||||
|
||||
@@ -164,7 +164,8 @@ eExprPyLike_EvalStatus BLI_expr_pylike_eval(ExprPyLike_Parsed *expr,
|
||||
#define FAIL_IF(condition) \
|
||||
if (condition) { \
|
||||
return EXPR_PYLIKE_FATAL_ERROR; \
|
||||
}
|
||||
} \
|
||||
((void)0)
|
||||
|
||||
/* Check the stack requirement is at least remotely sane and allocate on the actual stack. */
|
||||
FAIL_IF(expr->max_stack <= 0 || expr->max_stack > 1000);
|
||||
@@ -391,7 +392,8 @@ static BuiltinOpDef builtin_ops[] = {
|
||||
#define CHECK_ERROR(condition) \
|
||||
if (!(condition)) { \
|
||||
return false; \
|
||||
}
|
||||
} \
|
||||
((void)0)
|
||||
|
||||
/* For simplicity simple token types are represented by their own character;
|
||||
* these are special identifiers for multi-character tokens. */
|
||||
|
||||
@@ -154,7 +154,7 @@ static void FHT2D(
|
||||
for (i = 0; stm > 0; i++) {
|
||||
#define PRED(k) (((k & Nym) << Mx) + (k >> My))
|
||||
for (j = PRED(i); j > i; j = PRED(j)) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
if (j < i) {
|
||||
continue;
|
||||
|
||||
@@ -131,7 +131,6 @@ string ComponentNode::identifier() const
|
||||
const string typebuf = "" + to_string(static_cast<int>(type)) + ")";
|
||||
return typebuf + name + " : " + idname +
|
||||
"( affects_directly_visible: " + (affects_directly_visible ? "true" : "false") + ")";
|
||||
;
|
||||
}
|
||||
|
||||
OperationNode *ComponentNode::find_operation(OperationIDKey key) const
|
||||
|
||||
@@ -160,7 +160,7 @@ static void validate_pyconstraint_cb(Main *bmain, void *arg1, void *arg2)
|
||||
if (index) {
|
||||
/* innovative use of a for...loop to search */
|
||||
for (text = bmain->texts.first, i = 1; text && index != i; i++, text = text->id.next) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
}
|
||||
data->text = text;
|
||||
|
||||
@@ -1895,7 +1895,7 @@ static ProjPixel *project_paint_uvpixel_init(const ProjPaintState *ps,
|
||||
|
||||
/* other thread may be initializing the tile so wait here */
|
||||
while (projima->undoRect[tile_index] == TILE_PENDING) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
BLI_assert(tile_index < (IMAPAINT_TILE_NUMBER(ibuf->x) * IMAPAINT_TILE_NUMBER(ibuf->y)));
|
||||
|
||||
@@ -600,7 +600,7 @@ static UvSculptData *uv_sculpt_stroke_init(bContext *C, wmOperator *op, const wm
|
||||
if (do_island_optimization && (element->island != island_index)) {
|
||||
/* skip this uv if not on the active island */
|
||||
for (; element->next && !(element->next->separate); element = element->next) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -1847,7 +1847,6 @@ static bool draw_cache_view_cb(
|
||||
color[2] = 0.2f;
|
||||
stripe_ht = UI_view2d_region_to_view_y(v2d, 4.0f * UI_DPI_FAC * U.pixelsize) -
|
||||
v2d->cur.ymin;
|
||||
;
|
||||
stripe_bot = UI_view2d_region_to_view_y(v2d, V2D_SCROLL_HEIGHT_TEXT);
|
||||
stripe_top = stripe_bot + stripe_ht;
|
||||
break;
|
||||
|
||||
@@ -74,7 +74,7 @@ int text_do_suggest_select(SpaceText *st, ARegion *ar)
|
||||
|
||||
/* Count the visible lines to the cursor */
|
||||
for (tmp = st->text->curl, l = -st->top; tmp; tmp = tmp->prev, l++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
if (l < 0) {
|
||||
return 0;
|
||||
@@ -101,7 +101,7 @@ int text_do_suggest_select(SpaceText *st, ARegion *ar)
|
||||
|
||||
/* Work out which of the items is at the top of the visible list */
|
||||
for (i = 0, item = first; i < *top && item->next; i++, item = item->next) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
/* Work out the target item index in the visible list */
|
||||
@@ -111,7 +111,7 @@ int text_do_suggest_select(SpaceText *st, ARegion *ar)
|
||||
}
|
||||
|
||||
for (i = tgti; i > 0 && item->next; i--, item = item->next) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
if (item) {
|
||||
texttool_suggest_select(item);
|
||||
|
||||
@@ -1186,7 +1186,7 @@ static void draw_suggestion_list(const SpaceText *st, const TextDrawContext *tdc
|
||||
|
||||
/* Set the top 'item' of the visible list */
|
||||
for (i = 0, item = first; i < *top && item->next; i++, item = item->next) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
for (i = 0; i < SUGG_LIST_SIZE && item; i++, item = item->next) {
|
||||
|
||||
@@ -1268,7 +1268,7 @@ static int text_convert_whitespace_exec(bContext *C, wmOperator *op)
|
||||
for (j = 1;
|
||||
(j < tab_len) && (a + j < text_check_line_len) && (text_check_line[a + j] == ' ');
|
||||
j++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
if (j == tab_len) {
|
||||
|
||||
@@ -49,7 +49,8 @@ namespace Freestyle {
|
||||
long l = (long)(x) * (long)(y); \
|
||||
(z)[0] = LOW(l); \
|
||||
(z)[1] = HIGH(l); \
|
||||
}
|
||||
} \
|
||||
((void)0)
|
||||
|
||||
#define CARRY(x, y) ((unsigned long)((long)(x) + (long)(y)) > MASK)
|
||||
#define ADDEQU(x, y, z) (z = CARRY(x, (y)), x = LOW(x + (y)))
|
||||
|
||||
@@ -156,7 +156,7 @@ void imb_tile_cache_tile_free(ImBuf *ibuf, int tx, int ty)
|
||||
if (gtile) {
|
||||
/* in case another thread is loading this */
|
||||
while (gtile->loading) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
|
||||
BLI_ghash_remove(GLOBAL_CACHE.tilehash, gtile, NULL, NULL);
|
||||
@@ -295,7 +295,7 @@ static ImGlobalTile *imb_global_cache_get_tile(ImBuf *ibuf,
|
||||
BLI_mutex_unlock(&GLOBAL_CACHE.mutex);
|
||||
|
||||
while (gtile->loading) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
@@ -354,7 +354,7 @@ static int fwritecolrs(FILE *file, int width, int channels, unsigned char *ibufs
|
||||
for (cnt = 1; (cnt < 127) && ((beg + cnt) < width) &&
|
||||
(rgbe_scan[beg + cnt][i] == rgbe_scan[beg][i]);
|
||||
cnt++) {
|
||||
;
|
||||
/* pass */
|
||||
}
|
||||
if (cnt >= MINRUN) {
|
||||
break; /* long enough */
|
||||
|
||||
@@ -193,7 +193,7 @@ static const EnumPropertyItem snap_uv_element_items[] = {
|
||||
{0, NULL, 0, NULL, NULL},
|
||||
};
|
||||
|
||||
const EnumPropertyItem rna_enum_scene_display_aa_methods[] = {
|
||||
static const EnumPropertyItem rna_enum_scene_display_aa_methods[] = {
|
||||
{SCE_DISPLAY_AA_OFF,
|
||||
"OFF",
|
||||
0,
|
||||
|
||||
Reference in New Issue
Block a user