Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source/blender/blenkernel/BKE_volume.h2
-rw-r--r--source/blender/blenkernel/intern/anim_path.c2
-rw-r--r--source/blender/blenkernel/intern/anim_sys.c10
-rw-r--r--source/blender/blenkernel/intern/appdir.c2
-rw-r--r--source/blender/blenkernel/intern/attribute.c6
-rw-r--r--source/blender/blenkernel/intern/blender.c2
-rw-r--r--source/blender/blenkernel/intern/collection.c4
-rw-r--r--source/blender/blenkernel/intern/constraint.c4
-rw-r--r--source/blender/blenkernel/intern/customdata.c2
-rw-r--r--source/blender/blenkernel/intern/image.c6
-rw-r--r--source/blender/blenkernel/intern/key.c10
-rw-r--r--source/blender/blenkernel/intern/lib_id.c8
-rw-r--r--source/blender/blenkernel/intern/lib_id_delete.c2
-rw-r--r--source/blender/blenkernel/intern/lib_override.c6
-rw-r--r--source/blender/blenkernel/intern/lightprobe.c2
-rw-r--r--source/blender/blenkernel/intern/mask.c10
-rw-r--r--source/blender/blenkernel/intern/multires_inline.h2
-rw-r--r--source/blender/blenkernel/intern/multires_unsubdivide.c2
-rw-r--r--source/blender/blenkernel/intern/node.cc2
-rw-r--r--source/blender/blenkernel/intern/object.c8
-rw-r--r--source/blender/blenkernel/intern/pbvh.c2
-rw-r--r--source/blender/blenkernel/intern/rigidbody.c12
-rw-r--r--source/blender/blenkernel/intern/sound.c2
-rw-r--r--source/blender/blenkernel/intern/subdiv.c4
-rw-r--r--source/blender/blenkernel/intern/subdiv_ccg.c2
-rw-r--r--source/blender/blenkernel/intern/subdiv_converter.c4
-rw-r--r--source/blender/blenkernel/intern/subdiv_eval.c2
-rw-r--r--source/blender/blenkernel/intern/tracking.c2
-rw-r--r--source/blender/blenkernel/intern/tracking_util.c2
-rw-r--r--source/blender/blenkernel/intern/undo_system.c4
-rw-r--r--source/blender/blenkernel/intern/unit.c2
-rw-r--r--source/blender/blenlib/BLI_assert.h2
-rw-r--r--source/blender/blenlib/intern/BLI_mempool.c2
-rw-r--r--source/blender/blenlib/intern/expr_pylike_eval.c2
-rw-r--r--source/blender/blenlib/intern/math_color.c2
-rw-r--r--source/blender/blenlib/intern/task_range.cc2
-rw-r--r--source/blender/blenloader/intern/versioning_280.c2
-rw-r--r--source/blender/blenloader/intern/writefile.c4
-rw-r--r--source/blender/bmesh/intern/bmesh_construct.c8
-rw-r--r--source/blender/bmesh/intern/bmesh_log.c2
-rw-r--r--source/blender/bmesh/operators/bmo_hull.c2
-rw-r--r--source/blender/bmesh/tools/bmesh_bevel.c4
-rw-r--r--source/blender/compositor/intern/COM_CompositorContext.cc2
-rw-r--r--source/blender/compositor/intern/COM_ConstantFolder.cc2
-rw-r--r--source/blender/compositor/intern/COM_ExecutionSystem.cc2
-rw-r--r--source/blender/compositor/intern/COM_NodeOperation.cc2
-rw-r--r--source/blender/compositor/intern/COM_OpenCLDevice.cc2
-rw-r--r--source/blender/compositor/nodes/COM_RenderLayersNode.cc2
-rw-r--r--source/blender/compositor/operations/COM_RenderLayersProg.cc2
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder.cc2
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder_nodes.cc6
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder_relations.cc8
-rw-r--r--source/blender/depsgraph/intern/depsgraph.cc2
-rw-r--r--source/blender/depsgraph/intern/depsgraph_debug.cc2
-rw-r--r--source/blender/depsgraph/intern/depsgraph_physics.cc2
-rw-r--r--source/blender/depsgraph/intern/depsgraph_tag.cc4
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval.cc2
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc2
-rw-r--r--source/blender/depsgraph/intern/node/deg_node.cc8
-rw-r--r--source/blender/depsgraph/intern/node/deg_node_component.cc4
-rw-r--r--source/blender/depsgraph/intern/node/deg_node_id.cc2
-rw-r--r--source/blender/depsgraph/intern/node/deg_node_operation.cc2
-rw-r--r--source/blender/draw/engines/eevee/eevee_engine.c2
-rw-r--r--source/blender/draw/engines/image/image_engine.c2
-rw-r--r--source/blender/draw/engines/overlay/overlay_engine.c2
-rw-r--r--source/blender/draw/engines/workbench/workbench_materials.c2
-rw-r--r--source/blender/draw/intern/draw_cache_impl_particles.c2
-rw-r--r--source/blender/draw/intern/draw_shader.c2
-rw-r--r--source/blender/editors/armature/pose_slide.c2
-rw-r--r--source/blender/editors/curve/editcurve_add.c2
-rw-r--r--source/blender/editors/gpencil/gpencil_convert.c2
-rw-r--r--source/blender/editors/gpencil/gpencil_select.c2
-rw-r--r--source/blender/editors/interface/interface_handlers.c2
-rw-r--r--source/blender/editors/interface/interface_icons.c2
-rw-r--r--source/blender/editors/interface/interface_widgets.c4
-rw-r--r--source/blender/editors/interface/view2d_edge_pan.c2
-rw-r--r--source/blender/editors/mask/mask_ops.c2
-rw-r--r--source/blender/editors/object/object_relations.c2
-rw-r--r--source/blender/editors/render/render_preview.c6
-rw-r--r--source/blender/editors/render/render_shading.c2
-rw-r--r--source/blender/editors/screen/area.c2
-rw-r--r--source/blender/editors/screen/area_query.c2
-rw-r--r--source/blender/editors/screen/glutil.c4
-rw-r--r--source/blender/editors/sculpt_paint/sculpt.c2
-rw-r--r--source/blender/editors/sculpt_paint/sculpt_automasking.c6
-rw-r--r--source/blender/editors/sculpt_paint/sculpt_smooth.c2
-rw-r--r--source/blender/editors/sculpt_paint/sculpt_undo.c6
-rw-r--r--source/blender/editors/space_clip/clip_editor.c2
-rw-r--r--source/blender/editors/space_file/filesel.c4
-rw-r--r--source/blender/editors/space_outliner/outliner_tree.c7
-rw-r--r--source/blender/editors/space_outliner/tree/tree_element_id.cc2
-rw-r--r--source/blender/editors/space_sequencer/sequencer_draw.c2
-rw-r--r--source/blender/editors/space_view3d/view3d_select.c4
-rw-r--r--source/blender/editors/transform/transform_generics.c2
-rw-r--r--source/blender/editors/transform/transform_mode_edge_slide.c2
-rw-r--r--source/blender/editors/undo/ed_undo.c4
-rw-r--r--source/blender/editors/util/select_utils.c4
-rw-r--r--source/blender/gpu/intern/gpu_node_graph.c2
-rw-r--r--source/blender/gpu/intern/gpu_texture.cc4
-rw-r--r--source/blender/gpu/intern/gpu_uniform_buffer.cc4
-rw-r--r--source/blender/gpu/intern/gpu_viewport.c2
-rw-r--r--source/blender/gpu/opengl/gl_framebuffer.cc6
-rw-r--r--source/blender/imbuf/intern/colormanagement.c4
-rw-r--r--source/blender/imbuf/intern/indexer.c4
-rw-r--r--source/blender/io/alembic/exporter/abc_custom_props.cc2
-rw-r--r--source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc2
-rw-r--r--source/blender/io/alembic/exporter/abc_writer_instance.cc2
-rw-r--r--source/blender/io/usd/intern/usd_hierarchy_iterator.cc2
-rw-r--r--source/blender/io/usd/intern/usd_writer_abstract.cc2
-rw-r--r--source/blender/io/usd/intern/usd_writer_camera.cc2
-rw-r--r--source/blender/io/usd/intern/usd_writer_light.cc2
-rw-r--r--source/blender/makesdna/intern/dna_genfile.c2
-rw-r--r--source/blender/makesrna/intern/rna_access.c4
-rw-r--r--source/blender/makesrna/intern/rna_access_compare_override.c2
-rw-r--r--source/blender/makesrna/intern/rna_define.c2
-rw-r--r--source/blender/makesrna/intern/rna_mask.c2
-rw-r--r--source/blender/makesrna/intern/rna_nodetree.c4
-rw-r--r--source/blender/makesrna/intern/rna_object_force.c5
-rw-r--r--source/blender/makesrna/intern/rna_space.c2
-rw-r--r--source/blender/makesrna/intern/rna_ui.c4
-rw-r--r--source/blender/makesrna/intern/rna_wm.c4
-rw-r--r--source/blender/makesrna/intern/rna_wm_gizmo.c6
-rw-r--r--source/blender/nodes/geometry/nodes/node_geo_convex_hull.cc2
-rw-r--r--source/blender/python/intern/bpy_app_handlers.c2
-rw-r--r--source/blender/python/intern/bpy_rna.c8
-rw-r--r--source/blender/python/mathutils/mathutils_Color.c2
-rw-r--r--source/blender/sequencer/intern/image_cache.c2
-rw-r--r--source/blender/sequencer/intern/render.c2
-rw-r--r--source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c2
-rw-r--r--source/blender/windowmanager/intern/wm_cursors.c2
-rw-r--r--source/blender/windowmanager/intern/wm_dragdrop.c2
-rw-r--r--source/blender/windowmanager/intern/wm_files.c2
-rw-r--r--source/blender/windowmanager/intern/wm_keymap.c2
133 files changed, 217 insertions, 209 deletions
diff --git a/source/blender/blenkernel/BKE_volume.h b/source/blender/blenkernel/BKE_volume.h
index cf755827a6c..d9333996632 100644
--- a/source/blender/blenkernel/BKE_volume.h
+++ b/source/blender/blenkernel/BKE_volume.h
@@ -214,7 +214,7 @@ auto BKE_volume_grid_type_operation(const VolumeGridType grid_type, OpType &&op)
}
/* Should never be called. */
- BLI_assert(!"should never be reached");
+ BLI_assert_msg(0, "should never be reached");
return op.template operator()<openvdb::FloatGrid>();
}
diff --git a/source/blender/blenkernel/intern/anim_path.c b/source/blender/blenkernel/intern/anim_path.c
index e2c2708101b..de470a15041 100644
--- a/source/blender/blenkernel/intern/anim_path.c
+++ b/source/blender/blenkernel/intern/anim_path.c
@@ -216,7 +216,7 @@ static bool binary_search_anim_path(const float *accum_len_arr,
if (UNLIKELY(cur_step == 0)) {
/* This should never happen unless there is something horribly wrong. */
CLOG_ERROR(&LOG, "Couldn't find any valid point on the animation path!");
- BLI_assert(!"Couldn't find any valid point on the animation path!");
+ BLI_assert_msg(0, "Couldn't find any valid point on the animation path!");
return false;
}
diff --git a/source/blender/blenkernel/intern/anim_sys.c b/source/blender/blenkernel/intern/anim_sys.c
index 553453cd891..6164d4921b0 100644
--- a/source/blender/blenkernel/intern/anim_sys.c
+++ b/source/blender/blenkernel/intern/anim_sys.c
@@ -1457,7 +1457,7 @@ static float nla_blend_value(const int blendmode,
return influence * (lower_value * strip_value) + (1 - influence) * lower_value;
case NLASTRIP_MODE_COMBINE:
- BLI_assert(!"combine mode");
+ BLI_assert_msg(0, "combine mode");
ATTR_FALLTHROUGH;
default:
@@ -1495,7 +1495,7 @@ static float nla_combine_value(const int mix_mode,
return lower_value * powf(strip_value / base_value, influence);
default:
- BLI_assert(!"invalid mix mode");
+ BLI_assert_msg(0, "invalid mix mode");
return lower_value;
}
}
@@ -1546,7 +1546,7 @@ static bool nla_blend_get_inverted_strip_value(const int blendmode,
return true;
case NLASTRIP_MODE_COMBINE:
- BLI_assert(!"combine mode");
+ BLI_assert_msg(0, "combine mode");
ATTR_FALLTHROUGH;
default:
@@ -1602,7 +1602,7 @@ static bool nla_combine_get_inverted_strip_value(const int mix_mode,
return true;
default:
- BLI_assert(!"invalid mix mode");
+ BLI_assert_msg(0, "invalid mix mode");
return false;
}
}
@@ -3033,7 +3033,7 @@ bool BKE_animsys_nla_remap_keyframe_values(struct NlaKeyframingContext *context,
NlaEvalChannel *nec = nlaevalchan_verify_key(eval_data, NULL, &key);
BLI_assert(nec);
if (nec->base_snapshot.length != count) {
- BLI_assert(!"invalid value count");
+ BLI_assert_msg(0, "invalid value count");
nlaeval_snapshot_free_data(&blended_snapshot);
return false;
}
diff --git a/source/blender/blenkernel/intern/appdir.c b/source/blender/blenkernel/intern/appdir.c
index ebff6015df1..eae331fc7d1 100644
--- a/source/blender/blenkernel/intern/appdir.c
+++ b/source/blender/blenkernel/intern/appdir.c
@@ -779,7 +779,7 @@ const char *BKE_appdir_folder_id_version(const int folder_id,
default:
path[0] = '\0'; /* in case check_is_dir is false */
ok = false;
- BLI_assert(!"incorrect ID");
+ BLI_assert_msg(0, "incorrect ID");
break;
}
return ok ? path : NULL;
diff --git a/source/blender/blenkernel/intern/attribute.c b/source/blender/blenkernel/intern/attribute.c
index 5db45471f0a..ad2be4ffe30 100644
--- a/source/blender/blenkernel/intern/attribute.c
+++ b/source/blender/blenkernel/intern/attribute.c
@@ -119,7 +119,7 @@ bool BKE_id_attribute_rename(ID *id,
ReportList *reports)
{
if (BKE_id_attribute_required(id, layer)) {
- BLI_assert(!"Required attribute name is not editable");
+ BLI_assert_msg(0, "Required attribute name is not editable");
return false;
}
@@ -202,7 +202,7 @@ AttributeDomain BKE_id_attribute_domain(ID *id, CustomDataLayer *layer)
}
}
- BLI_assert(!"Custom data layer not found in geometry");
+ BLI_assert_msg(0, "Custom data layer not found in geometry");
return ATTR_DOMAIN_NUM;
}
@@ -218,7 +218,7 @@ int BKE_id_attribute_data_length(ID *id, CustomDataLayer *layer)
}
}
- BLI_assert(!"Custom data layer not found in geometry");
+ BLI_assert_msg(0, "Custom data layer not found in geometry");
return 0;
}
diff --git a/source/blender/blenkernel/intern/blender.c b/source/blender/blenkernel/intern/blender.c
index e84b485c466..97a54f289ee 100644
--- a/source/blender/blenkernel/intern/blender.c
+++ b/source/blender/blenkernel/intern/blender.c
@@ -127,7 +127,7 @@ static void blender_version_init(void)
version_cycle = "";
}
else {
- BLI_assert(!"Invalid Blender version cycle");
+ BLI_assert_msg(0, "Invalid Blender version cycle");
}
BLI_snprintf(blender_version_string,
diff --git a/source/blender/blenkernel/intern/collection.c b/source/blender/blenkernel/intern/collection.c
index cf32bc15962..c354115e030 100644
--- a/source/blender/blenkernel/intern/collection.c
+++ b/source/blender/blenkernel/intern/collection.c
@@ -191,7 +191,7 @@ static ID *collection_owner_get(Main *bmain, ID *id)
}
}
- BLI_assert(!"Embedded collection with no owner. Critical Main inconsistency.");
+ BLI_assert_msg(0, "Embedded collection with no owner. Critical Main inconsistency.");
return NULL;
}
@@ -522,7 +522,7 @@ bool BKE_collection_delete(Main *bmain, Collection *collection, bool hierarchy)
{
/* Master collection is not real datablock, can't be removed. */
if (collection->flag & COLLECTION_IS_MASTER) {
- BLI_assert(!"Scene master collection can't be deleted");
+ BLI_assert_msg(0, "Scene master collection can't be deleted");
return false;
}
diff --git a/source/blender/blenkernel/intern/constraint.c b/source/blender/blenkernel/intern/constraint.c
index bc993d8d58d..47df31e3a2c 100644
--- a/source/blender/blenkernel/intern/constraint.c
+++ b/source/blender/blenkernel/intern/constraint.c
@@ -2339,7 +2339,7 @@ static void translike_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *t
break;
default:
- BLI_assert(!"Unknown Copy Transforms mix mode");
+ BLI_assert_msg(0, "Unknown Copy Transforms mix mode");
}
}
}
@@ -2991,7 +2991,7 @@ static void actcon_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targ
break;
default:
- BLI_assert(!"Unknown Action mix mode");
+ BLI_assert_msg(0, "Unknown Action mix mode");
}
}
}
diff --git a/source/blender/blenkernel/intern/customdata.c b/source/blender/blenkernel/intern/customdata.c
index 4c0849d18de..7aa9d1958eb 100644
--- a/source/blender/blenkernel/intern/customdata.c
+++ b/source/blender/blenkernel/intern/customdata.c
@@ -3557,7 +3557,7 @@ bool CustomData_bmesh_merge(const CustomData *source,
totelem = bm->totface;
break;
default: /* should never happen */
- BLI_assert(!"invalid type given");
+ BLI_assert_msg(0, "invalid type given");
iter_type = BM_VERTS_OF_MESH;
totelem = bm->totvert;
break;
diff --git a/source/blender/blenkernel/intern/image.c b/source/blender/blenkernel/intern/image.c
index 9eee6231ebf..f4ba1ff8b92 100644
--- a/source/blender/blenkernel/intern/image.c
+++ b/source/blender/blenkernel/intern/image.c
@@ -1778,7 +1778,7 @@ static bool do_add_image_extension(char *string,
}
}
else {
- BLI_assert(!"Unsupported jp2 codec was specified in im_format->jp2_codec");
+ BLI_assert_msg(0, "Unsupported jp2 codec was specified in im_format->jp2_codec");
}
}
else {
@@ -1949,7 +1949,7 @@ void BKE_imbuf_to_image_format(struct ImageFormatData *im_format, const ImBuf *i
im_format->jp2_codec = R_IMF_JP2_CODEC_J2K;
}
else {
- BLI_assert(!"Unsupported jp2 codec was specified in file type");
+ BLI_assert_msg(0, "Unsupported jp2 codec was specified in file type");
}
}
#endif
@@ -3017,7 +3017,7 @@ void BKE_imbuf_write_prepare(ImBuf *ibuf, const ImageFormatData *imf)
ibuf->foptions.flag |= JP2_J2K;
}
else {
- BLI_assert(!"Unsupported jp2 codec was specified in im_format->jp2_codec");
+ BLI_assert_msg(0, "Unsupported jp2 codec was specified in im_format->jp2_codec");
}
}
#endif
diff --git a/source/blender/blenkernel/intern/key.c b/source/blender/blenkernel/intern/key.c
index 52f888d9543..0f8c9bad798 100644
--- a/source/blender/blenkernel/intern/key.c
+++ b/source/blender/blenkernel/intern/key.c
@@ -694,7 +694,7 @@ static bool key_pointer_size(const Key *key, const int mode, int *poinsize, int
*poinsize = sizeof(float[KEYELEM_ELEM_SIZE_CURVE]);
break;
default:
- BLI_assert(!"invalid 'key->from' ID type");
+ BLI_assert_msg(0, "invalid 'key->from' ID type");
return false;
}
@@ -806,7 +806,7 @@ static void cp_key(const int start,
if (freekref) {
MEM_freeN(freekref);
}
- BLI_assert(!"invalid 'cp[1]'");
+ BLI_assert_msg(0, "invalid 'cp[1]'");
return;
}
@@ -984,7 +984,7 @@ static void key_evaluate_relative(const int start,
if (freefrom) {
MEM_freeN(freefrom);
}
- BLI_assert(!"invalid 'cp[1]'");
+ BLI_assert_msg(0, "invalid 'cp[1]'");
return;
}
@@ -1204,7 +1204,7 @@ static void do_key(const int start,
if (freek4) {
MEM_freeN(freek4);
}
- BLI_assert(!"invalid 'cp[1]'");
+ BLI_assert_msg(0, "invalid 'cp[1]'");
return;
}
@@ -1695,7 +1695,7 @@ void BKE_keyblock_data_set_with_mat4(Key *key,
const float mat[4][4])
{
if (key->elemsize != sizeof(float[3])) {
- BLI_assert(!"Invalid elemsize");
+ BLI_assert_msg(0, "Invalid elemsize");
return;
}
diff --git a/source/blender/blenkernel/intern/lib_id.c b/source/blender/blenkernel/intern/lib_id.c
index 9d0349a7e89..62d29188c5a 100644
--- a/source/blender/blenkernel/intern/lib_id.c
+++ b/source/blender/blenkernel/intern/lib_id.c
@@ -499,7 +499,7 @@ bool BKE_lib_id_make_local(Main *bmain, ID *id, const bool test, const int flags
return false;
}
- BLI_assert(!"IDType Missing IDTypeInfo");
+ BLI_assert_msg(0, "IDType Missing IDTypeInfo");
return false;
}
@@ -603,7 +603,7 @@ ID *BKE_id_copy_ex(Main *bmain, const ID *id, ID **r_newid, const int flag)
}
}
else {
- BLI_assert(!"IDType Missing IDTypeInfo");
+ BLI_assert_msg(0, "IDType Missing IDTypeInfo");
}
/* Update ID refcount, remap pointers to self in new ID. */
@@ -1053,7 +1053,7 @@ void *BKE_libblock_alloc_notest(short type)
if (size != 0) {
return MEM_callocN(size, name);
}
- BLI_assert(!"Request to allocate unknown data type");
+ BLI_assert_msg(0, "Request to allocate unknown data type");
return NULL;
}
@@ -1134,7 +1134,7 @@ void BKE_libblock_init_empty(ID *id)
return;
}
- BLI_assert(!"IDType Missing IDTypeInfo");
+ BLI_assert_msg(0, "IDType Missing IDTypeInfo");
}
/* ********** ID session-wise UUID management. ********** */
diff --git a/source/blender/blenkernel/intern/lib_id_delete.c b/source/blender/blenkernel/intern/lib_id_delete.c
index 7ea321b0ee1..a9407860c06 100644
--- a/source/blender/blenkernel/intern/lib_id_delete.c
+++ b/source/blender/blenkernel/intern/lib_id_delete.c
@@ -83,7 +83,7 @@ void BKE_libblock_free_datablock(ID *id, const int UNUSED(flag))
return;
}
- BLI_assert(!"IDType Missing IDTypeInfo");
+ BLI_assert_msg(0, "IDType Missing IDTypeInfo");
}
/**
diff --git a/source/blender/blenkernel/intern/lib_override.c b/source/blender/blenkernel/intern/lib_override.c
index b5384186c69..9871bf5dc83 100644
--- a/source/blender/blenkernel/intern/lib_override.c
+++ b/source/blender/blenkernel/intern/lib_override.c
@@ -94,7 +94,7 @@ BLI_INLINE IDOverrideLibrary *lib_override_get(Main *bmain, ID *id)
if (id_type->owner_get != NULL) {
return id_type->owner_get(bmain, id)->override_library;
}
- BLI_assert(!"IDTypeInfo of liboverride-embedded ID with no owner getter");
+ BLI_assert_msg(0, "IDTypeInfo of liboverride-embedded ID with no owner getter");
}
return id->override_library;
}
@@ -2126,7 +2126,7 @@ bool BKE_lib_override_library_property_operation_operands_validate(
ATTR_FALLTHROUGH;
case IDOVERRIDE_LIBRARY_OP_MULTIPLY:
if (ptr_storage == NULL || ptr_storage->data == NULL || prop_storage == NULL) {
- BLI_assert(!"Missing data to apply differential override operation.");
+ BLI_assert_msg(0, "Missing data to apply differential override operation.");
return false;
}
ATTR_FALLTHROUGH;
@@ -2137,7 +2137,7 @@ bool BKE_lib_override_library_property_operation_operands_validate(
case IDOVERRIDE_LIBRARY_OP_REPLACE:
if ((ptr_dst == NULL || ptr_dst->data == NULL || prop_dst == NULL) ||
(ptr_src == NULL || ptr_src->data == NULL || prop_src == NULL)) {
- BLI_assert(!"Missing data to apply override operation.");
+ BLI_assert_msg(0, "Missing data to apply override operation.");
return false;
}
}
diff --git a/source/blender/blenkernel/intern/lightprobe.c b/source/blender/blenkernel/intern/lightprobe.c
index d872ecf7578..b09aed82921 100644
--- a/source/blender/blenkernel/intern/lightprobe.c
+++ b/source/blender/blenkernel/intern/lightprobe.c
@@ -131,7 +131,7 @@ void BKE_lightprobe_type_set(LightProbe *probe, const short lightprobe_type)
probe->attenuation_type = LIGHTPROBE_SHAPE_ELIPSOID;
break;
default:
- BLI_assert(!"LightProbe type not configured.");
+ BLI_assert_msg(0, "LightProbe type not configured.");
break;
}
}
diff --git a/source/blender/blenkernel/intern/mask.c b/source/blender/blenkernel/intern/mask.c
index ee71d60f1e3..34dd38164c2 100644
--- a/source/blender/blenkernel/intern/mask.c
+++ b/source/blender/blenkernel/intern/mask.c
@@ -342,7 +342,7 @@ MaskSplinePoint *BKE_mask_spline_point_array_from_point(MaskSpline *spline,
return spline->points_deform;
}
- BLI_assert(!"wrong array");
+ BLI_assert_msg(0, "wrong array");
return NULL;
}
@@ -707,7 +707,7 @@ void BKE_mask_point_handle(const MaskSplinePoint *point,
copy_v2_v2(r_handle, bezt->vec[2]);
}
else {
- BLI_assert(!"Unknown handle passed to BKE_mask_point_handle");
+ BLI_assert_msg(0, "Unknown handle passed to BKE_mask_point_handle");
}
}
@@ -760,7 +760,7 @@ void BKE_mask_point_set_handle(MaskSplinePoint *point,
copy_v2_v2(bezt->vec[2], loc);
}
else {
- BLI_assert(!"unknown handle passed to BKE_mask_point_set_handle");
+ BLI_assert_msg(0, "unknown handle passed to BKE_mask_point_set_handle");
}
}
@@ -1003,7 +1003,7 @@ void BKE_mask_point_select_set_handle(MaskSplinePoint *point,
point->bezt.f3 |= SELECT;
}
else {
- BLI_assert(!"Wrong which_handle passed to BKE_mask_point_select_set_handle");
+ BLI_assert_msg(0, "Wrong which_handle passed to BKE_mask_point_select_set_handle");
}
}
else {
@@ -1018,7 +1018,7 @@ void BKE_mask_point_select_set_handle(MaskSplinePoint *point,
point->bezt.f3 &= ~SELECT;
}
else {
- BLI_assert(!"Wrong which_handle passed to BKE_mask_point_select_set_handle");
+ BLI_assert_msg(0, "Wrong which_handle passed to BKE_mask_point_select_set_handle");
}
}
}
diff --git a/source/blender/blenkernel/intern/multires_inline.h b/source/blender/blenkernel/intern/multires_inline.h
index e85aa12781e..f88b5dd3143 100644
--- a/source/blender/blenkernel/intern/multires_inline.h
+++ b/source/blender/blenkernel/intern/multires_inline.h
@@ -53,7 +53,7 @@ BLI_INLINE void BKE_multires_construct_tangent_matrix(float tangent_matrix[3][3]
mul_v3_fl(tangent_matrix[0], -1.0f);
}
else {
- BLI_assert(!"Unhandled corner index");
+ BLI_assert_msg(0, "Unhandled corner index");
}
cross_v3_v3v3(tangent_matrix[2], dPdu, dPdv);
normalize_v3(tangent_matrix[0]);
diff --git a/source/blender/blenkernel/intern/multires_unsubdivide.c b/source/blender/blenkernel/intern/multires_unsubdivide.c
index 4210f26a694..501e3f27389 100644
--- a/source/blender/blenkernel/intern/multires_unsubdivide.c
+++ b/source/blender/blenkernel/intern/multires_unsubdivide.c
@@ -603,7 +603,7 @@ static void write_loop_in_face_grid(
step_y[1] = 0;
break;
default:
- BLI_assert(!"Should never happen");
+ BLI_assert_msg(0, "Should never happen");
break;
}
diff --git a/source/blender/blenkernel/intern/node.cc b/source/blender/blenkernel/intern/node.cc
index e4c259ec9fc..633ec1707f9 100644
--- a/source/blender/blenkernel/intern/node.cc
+++ b/source/blender/blenkernel/intern/node.cc
@@ -399,7 +399,7 @@ static ID *node_owner_get(Main *bmain, ID *id)
}
}
- BLI_assert(!"Embedded node tree with no owner. Critical Main inconsistency.");
+ BLI_assert_msg(0, "Embedded node tree with no owner. Critical Main inconsistency.");
return nullptr;
}
diff --git a/source/blender/blenkernel/intern/object.c b/source/blender/blenkernel/intern/object.c
index 912b5e0a0dd..941db80b76c 100644
--- a/source/blender/blenkernel/intern/object.c
+++ b/source/blender/blenkernel/intern/object.c
@@ -205,7 +205,8 @@ static void object_copy_data(Main *bmain, ID *id_dst, const ID *id_src, const in
}
else if (ob_dst->mat != NULL || ob_dst->matbits != NULL) {
/* This shall not be needed, but better be safe than sorry. */
- BLI_assert(!"Object copy: non-NULL material pointers with zero counter, should not happen.");
+ BLI_assert_msg(
+ 0, "Object copy: non-NULL material pointers with zero counter, should not happen.");
ob_dst->mat = NULL;
ob_dst->matbits = NULL;
}
@@ -1532,7 +1533,8 @@ bool BKE_object_modifier_stack_copy(Object *ob_dst,
const int flag_subdata)
{
if ((ob_dst->type == OB_GPENCIL) != (ob_src->type == OB_GPENCIL)) {
- BLI_assert(!"Trying to copy a modifier stack between a GPencil object and another type.");
+ BLI_assert_msg(0,
+ "Trying to copy a modifier stack between a GPencil object and another type.");
return false;
}
@@ -3335,7 +3337,7 @@ static void give_parvert(Object *par, int nr, float vec[3])
}
BLI_mutex_unlock(&vparent_lock);
#else
- BLI_assert(!"Not safe for threading");
+ BLI_assert_msg(0, "Not safe for threading");
BM_mesh_elem_table_ensure(em->bm, BM_VERT);
#endif
}
diff --git a/source/blender/blenkernel/intern/pbvh.c b/source/blender/blenkernel/intern/pbvh.c
index 1f8f9ce63ac..461ffa7765e 100644
--- a/source/blender/blenkernel/intern/pbvh.c
+++ b/source/blender/blenkernel/intern/pbvh.c
@@ -2798,7 +2798,7 @@ float (*BKE_pbvh_vert_coords_alloc(PBVH *pbvh))[3]
void BKE_pbvh_vert_coords_apply(PBVH *pbvh, const float (*vertCos)[3], const int totvert)
{
if (totvert != pbvh->totvert) {
- BLI_assert(!"PBVH: Given deforming vcos number does not natch PBVH vertex number!");
+ BLI_assert_msg(0, "PBVH: Given deforming vcos number does not natch PBVH vertex number!");
return;
}
diff --git a/source/blender/blenkernel/intern/rigidbody.c b/source/blender/blenkernel/intern/rigidbody.c
index 9c6610f88fd..328c54fc21b 100644
--- a/source/blender/blenkernel/intern/rigidbody.c
+++ b/source/blender/blenkernel/intern/rigidbody.c
@@ -367,7 +367,7 @@ static Mesh *rigidbody_get_mesh(Object *ob)
}
/* Just return something sensible so that at least Blender won't crash. */
- BLI_assert(!"Unknown mesh source");
+ BLI_assert_msg(0, "Unknown mesh source");
return BKE_object_get_evaluated_mesh(ob);
}
@@ -1814,8 +1814,9 @@ static void rigidbody_update_simulation(Depsgraph *depsgraph,
/* TODO: remove this whole block once we are sure we never get NULL rbo here anymore. */
/* This cannot be done in CoW evaluation context anymore... */
if (rbo == NULL) {
- BLI_assert(!"CoW object part of RBW object collection without RB object data, "
- "should not happen.\n");
+ BLI_assert_msg(0,
+ "CoW object part of RBW object collection without RB object data, "
+ "should not happen.\n");
/* Since this object is included in the sim group but doesn't have
* rigid body settings (perhaps it was added manually), add!
* - assume object to be active? That is the default for newly added settings...
@@ -1871,8 +1872,9 @@ static void rigidbody_update_simulation(Depsgraph *depsgraph,
/* TODO: remove this whole block once we are sure we never get NULL rbo here anymore. */
/* This cannot be done in CoW evaluation context anymore... */
if (rbc == NULL) {
- BLI_assert(!"CoW object part of RBW constraints collection without RB constraint data, "
- "should not happen.\n");
+ BLI_assert_msg(0,
+ "CoW object part of RBW constraints collection without RB constraint data, "
+ "should not happen.\n");
/* Since this object is included in the group but doesn't have
* constraint settings (perhaps it was added manually), add!
*/
diff --git a/source/blender/blenkernel/intern/sound.c b/source/blender/blenkernel/intern/sound.c
index f4a9d328d86..fcb992e1535 100644
--- a/source/blender/blenkernel/intern/sound.c
+++ b/source/blender/blenkernel/intern/sound.c
@@ -824,7 +824,7 @@ void BKE_sound_set_scene_sound_pan(void *handle, float pan, char animated)
void BKE_sound_update_sequencer(Main *main, bSound *sound)
{
- BLI_assert(!"is not supposed to be used, is weird function.");
+ BLI_assert_msg(0, "is not supposed to be used, is weird function.");
Scene *scene;
diff --git a/source/blender/blenkernel/intern/subdiv.c b/source/blender/blenkernel/intern/subdiv.c
index e6b51c586c3..fd32f52351a 100644
--- a/source/blender/blenkernel/intern/subdiv.c
+++ b/source/blender/blenkernel/intern/subdiv.c
@@ -68,7 +68,7 @@ eSubdivFVarLinearInterpolation BKE_subdiv_fvar_interpolation_from_uv_smooth(int
case SUBSURF_UV_SMOOTH_ALL:
return SUBDIV_FVAR_LINEAR_INTERPOLATION_NONE;
}
- BLI_assert(!"Unknown uv smooth flag");
+ BLI_assert_msg(0, "Unknown uv smooth flag");
return SUBDIV_FVAR_LINEAR_INTERPOLATION_ALL;
}
@@ -81,7 +81,7 @@ eSubdivVtxBoundaryInterpolation BKE_subdiv_vtx_boundary_interpolation_from_subsu
case SUBSURF_BOUNDARY_SMOOTH_ALL:
return SUBDIV_VTX_BOUNDARY_EDGE_ONLY;
}
- BLI_assert(!"Unknown boundary smooth flag");
+ BLI_assert_msg(0, "Unknown boundary smooth flag");
return SUBDIV_VTX_BOUNDARY_EDGE_ONLY;
}
diff --git a/source/blender/blenkernel/intern/subdiv_ccg.c b/source/blender/blenkernel/intern/subdiv_ccg.c
index 8b672b2cb49..95f51a72b70 100644
--- a/source/blender/blenkernel/intern/subdiv_ccg.c
+++ b/source/blender/blenkernel/intern/subdiv_ccg.c
@@ -1509,7 +1509,7 @@ static SubdivCCGCoord coord_step_inside_from_boundary(const SubdivCCG *subdiv_cc
++result.y;
}
else {
- BLI_assert(!"non-boundary element given");
+ BLI_assert_msg(0, "non-boundary element given");
}
return result;
}
diff --git a/source/blender/blenkernel/intern/subdiv_converter.c b/source/blender/blenkernel/intern/subdiv_converter.c
index d5c75503500..39b701da262 100644
--- a/source/blender/blenkernel/intern/subdiv_converter.c
+++ b/source/blender/blenkernel/intern/subdiv_converter.c
@@ -44,7 +44,7 @@ int BKE_subdiv_converter_vtx_boundary_interpolation_from_settings(const SubdivSe
case SUBDIV_VTX_BOUNDARY_EDGE_AND_CORNER:
return OSD_VTX_BOUNDARY_EDGE_AND_CORNER;
}
- BLI_assert(!"Unknown vtx boundary interpolation");
+ BLI_assert_msg(0, "Unknown vtx boundary interpolation");
return OSD_VTX_BOUNDARY_EDGE_ONLY;
}
@@ -65,6 +65,6 @@ int BKE_subdiv_converter_vtx_boundary_interpolation_from_settings(const SubdivSe
case SUBDIV_FVAR_LINEAR_INTERPOLATION_ALL:
return OSD_FVAR_LINEAR_INTERPOLATION_ALL;
}
- BLI_assert(!"Unknown fvar linear interpolation");
+ BLI_assert_msg(0, "Unknown fvar linear interpolation");
return OSD_FVAR_LINEAR_INTERPOLATION_NONE;
}
diff --git a/source/blender/blenkernel/intern/subdiv_eval.c b/source/blender/blenkernel/intern/subdiv_eval.c
index 693827f99ac..0001eb8a205 100644
--- a/source/blender/blenkernel/intern/subdiv_eval.c
+++ b/source/blender/blenkernel/intern/subdiv_eval.c
@@ -137,7 +137,7 @@ bool BKE_subdiv_eval_refine_from_mesh(Subdiv *subdiv,
{
if (subdiv->evaluator == NULL) {
/* NOTE: This situation is supposed to be handled by begin(). */
- BLI_assert(!"Is not supposed to happen");
+ BLI_assert_msg(0, "Is not supposed to happen");
return false;
}
/* Set coordinates of base mesh vertices. */
diff --git a/source/blender/blenkernel/intern/tracking.c b/source/blender/blenkernel/intern/tracking.c
index f3d6bc4a6e3..068d048fd08 100644
--- a/source/blender/blenkernel/intern/tracking.c
+++ b/source/blender/blenkernel/intern/tracking.c
@@ -1525,7 +1525,7 @@ MovieTrackingMarker *BKE_tracking_marker_get(MovieTrackingTrack *track, int fram
const int num_markers = track->markersnr;
if (num_markers == 0) {
- BLI_assert(!"Detected degenerated track, should never happen.");
+ BLI_assert_msg(0, "Detected degenerated track, should never happen.");
return NULL;
}
diff --git a/source/blender/blenkernel/intern/tracking_util.c b/source/blender/blenkernel/intern/tracking_util.c
index ea0d92cf78e..16b36e94328 100644
--- a/source/blender/blenkernel/intern/tracking_util.c
+++ b/source/blender/blenkernel/intern/tracking_util.c
@@ -523,7 +523,7 @@ static void distortion_model_parameters_from_options(
/* Libmv returned distortion model which is not known to Blender. This is a logical error in code
* and Blender side is to be updated to match Libmv. */
- BLI_assert(!"Unknown distortion model");
+ BLI_assert_msg(0, "Unknown distortion model");
}
/* Fill in Libmv C-API camera intrinsics options from tracking structure. */
diff --git a/source/blender/blenkernel/intern/undo_system.c b/source/blender/blenkernel/intern/undo_system.c
index 03bd9323f39..e524bd254bb 100644
--- a/source/blender/blenkernel/intern/undo_system.c
+++ b/source/blender/blenkernel/intern/undo_system.c
@@ -717,7 +717,9 @@ eUndoStepDir BKE_undosys_step_calc_direction(const UndoStack *ustack,
}
}
- BLI_assert(!"Target undo step not found, this should not happen and may indicate an undo stack corruption");
+ BLI_assert_msg(0,
+ "Target undo step not found, this should not happen and may indicate an undo "
+ "stack corruption");
return STEP_INVALID;
}
diff --git a/source/blender/blenkernel/intern/unit.c b/source/blender/blenkernel/intern/unit.c
index f87f1c0428b..d9f02ce4c75 100644
--- a/source/blender/blenkernel/intern/unit.c
+++ b/source/blender/blenkernel/intern/unit.c
@@ -833,7 +833,7 @@ static char *find_next_op(const char *str, char *remaining_str, int len_max)
return remaining_str + i;
}
}
- BLI_assert(!"String should be NULL terminated");
+ BLI_assert_msg(0, "String should be NULL terminated");
return remaining_str + i;
}
diff --git a/source/blender/blenlib/BLI_assert.h b/source/blender/blenlib/BLI_assert.h
index 7f7bec425ce..6019f0f3566 100644
--- a/source/blender/blenlib/BLI_assert.h
+++ b/source/blender/blenlib/BLI_assert.h
@@ -106,7 +106,7 @@ void _BLI_assert_unreachable_print(const char *file, const int line, const char
#define BLI_assert_unreachable() \
{ \
_BLI_assert_unreachable_print(__FILE__, __LINE__, __func__); \
- BLI_assert(!"This line of code is marked to be unreachable."); \
+ BLI_assert_msg(0, "This line of code is marked to be unreachable."); \
} \
((void)0)
diff --git a/source/blender/blenlib/intern/BLI_mempool.c b/source/blender/blenlib/intern/BLI_mempool.c
index ff17f816588..5263af2ae56 100644
--- a/source/blender/blenlib/intern/BLI_mempool.c
+++ b/source/blender/blenlib/intern/BLI_mempool.c
@@ -387,7 +387,7 @@ void BLI_mempool_free(BLI_mempool *pool, void *addr)
}
}
if (!found) {
- BLI_assert(!"Attempt to free data which is not in pool.\n");
+ BLI_assert_msg(0, "Attempt to free data which is not in pool.\n");
}
}
diff --git a/source/blender/blenlib/intern/expr_pylike_eval.c b/source/blender/blenlib/intern/expr_pylike_eval.c
index a5d4130cb20..4d1ba190c14 100644
--- a/source/blender/blenlib/intern/expr_pylike_eval.c
+++ b/source/blender/blenlib/intern/expr_pylike_eval.c
@@ -569,7 +569,7 @@ static int opcode_arg_count(eOpCode code)
case OPCODE_FUNC3:
return 3;
default:
- BLI_assert(!"unexpected opcode");
+ BLI_assert_msg(0, "unexpected opcode");
return -1;
}
}
diff --git a/source/blender/blenlib/intern/math_color.c b/source/blender/blenlib/intern/math_color.c
index 263c508c07c..da97e697f2f 100644
--- a/source/blender/blenlib/intern/math_color.c
+++ b/source/blender/blenlib/intern/math_color.c
@@ -153,7 +153,7 @@ void rgb_to_ycc(float r, float g, float b, float *r_y, float *r_cb, float *r_cr,
cr = (0.5f * sr) - (0.41869f * sg) - (0.08131f * sb) + 128.0f;
break;
default:
- BLI_assert(!"invalid colorspace");
+ BLI_assert_msg(0, "invalid colorspace");
break;
}
diff --git a/source/blender/blenlib/intern/task_range.cc b/source/blender/blenlib/intern/task_range.cc
index 871d04c1f35..8407be2cb2b 100644
--- a/source/blender/blenlib/intern/task_range.cc
+++ b/source/blender/blenlib/intern/task_range.cc
@@ -156,7 +156,7 @@ int BLI_task_parallel_thread_id(const TaskParallelTLS *UNUSED(tls))
if (thread_id == -1) {
thread_id = atomic_fetch_and_add_int32(&tbb_thread_id_counter, 1);
if (thread_id >= BLENDER_MAX_THREADS) {
- BLI_assert(!"Maximum number of threads exceeded for sculpting");
+ BLI_assert_msg(0, "Maximum number of threads exceeded for sculpting");
thread_id = thread_id % BLENDER_MAX_THREADS;
}
}
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c
index 82c4709f187..0645380c4cb 100644
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@ -670,7 +670,7 @@ static ARegion *do_versions_find_region(ListBase *regionbase, int regiontype)
{
ARegion *region = do_versions_find_region_or_null(regionbase, regiontype);
if (region == NULL) {
- BLI_assert(!"Did not find expected region in versioning");
+ BLI_assert_msg(0, "Did not find expected region in versioning");
}
return region;
}
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index 4802c495ef2..fc29b1d8915 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -304,7 +304,7 @@ static void writedata_do_write(WriteData *wd, const void *mem, size_t memlen)
}
if (memlen > INT_MAX) {
- BLI_assert(!"Cannot write chunks bigger than INT_MAX.");
+ BLI_assert_msg(0, "Cannot write chunks bigger than INT_MAX.");
return;
}
@@ -538,7 +538,7 @@ static void writedata(WriteData *wd, int filecode, size_t len, const void *adr)
}
if (len > INT_MAX) {
- BLI_assert(!"Cannot write chunks bigger than INT_MAX.");
+ BLI_assert_msg(0, "Cannot write chunks bigger than INT_MAX.");
return;
}
diff --git a/source/blender/bmesh/intern/bmesh_construct.c b/source/blender/bmesh/intern/bmesh_construct.c
index f79f1925560..ee51a03d9fb 100644
--- a/source/blender/bmesh/intern/bmesh_construct.c
+++ b/source/blender/bmesh/intern/bmesh_construct.c
@@ -415,7 +415,7 @@ static void bm_vert_attrs_copy(
BMesh *bm_src, BMesh *bm_dst, const BMVert *v_src, BMVert *v_dst, CustomDataMask mask_exclude)
{
if ((bm_src == bm_dst) && (v_src == v_dst)) {
- BLI_assert(!"BMVert: source and target match");
+ BLI_assert_msg(0, "BMVert: source and target match");
return;
}
if ((mask_exclude & CD_MASK_NORMAL) == 0) {
@@ -430,7 +430,7 @@ static void bm_edge_attrs_copy(
BMesh *bm_src, BMesh *bm_dst, const BMEdge *e_src, BMEdge *e_dst, CustomDataMask mask_exclude)
{
if ((bm_src == bm_dst) && (e_src == e_dst)) {
- BLI_assert(!"BMEdge: source and target match");
+ BLI_assert_msg(0, "BMEdge: source and target match");
return;
}
CustomData_bmesh_free_block_data_exclude_by_type(&bm_dst->edata, e_dst->head.data, mask_exclude);
@@ -442,7 +442,7 @@ static void bm_loop_attrs_copy(
BMesh *bm_src, BMesh *bm_dst, const BMLoop *l_src, BMLoop *l_dst, CustomDataMask mask_exclude)
{
if ((bm_src == bm_dst) && (l_src == l_dst)) {
- BLI_assert(!"BMLoop: source and target match");
+ BLI_assert_msg(0, "BMLoop: source and target match");
return;
}
CustomData_bmesh_free_block_data_exclude_by_type(&bm_dst->ldata, l_dst->head.data, mask_exclude);
@@ -454,7 +454,7 @@ static void bm_face_attrs_copy(
BMesh *bm_src, BMesh *bm_dst, const BMFace *f_src, BMFace *f_dst, CustomDataMask mask_exclude)
{
if ((bm_src == bm_dst) && (f_src == f_dst)) {
- BLI_assert(!"BMFace: source and target match");
+ BLI_assert_msg(0, "BMFace: source and target match");
return;
}
if ((mask_exclude & CD_MASK_NORMAL) == 0) {
diff --git a/source/blender/bmesh/intern/bmesh_log.c b/source/blender/bmesh/intern/bmesh_log.c
index 1febae54b39..9033e43374b 100644
--- a/source/blender/bmesh/intern/bmesh_log.c
+++ b/source/blender/bmesh/intern/bmesh_log.c
@@ -740,7 +740,7 @@ void BM_log_entry_drop(BMLogEntry *entry)
bm_log_id_ghash_release(log, entry->added_verts);
}
else {
- BLI_assert(!"Cannot drop BMLogEntry from middle");
+ BLI_assert_msg(0, "Cannot drop BMLogEntry from middle");
}
if (log->current_entry == entry) {
diff --git a/source/blender/bmesh/operators/bmo_hull.c b/source/blender/bmesh/operators/bmo_hull.c
index 0801300b6c2..740815691cc 100644
--- a/source/blender/bmesh/operators/bmo_hull.c
+++ b/source/blender/bmesh/operators/bmo_hull.c
@@ -465,7 +465,7 @@ static BMVert **hull_verts_from_bullet(plConvexHull hull,
hull_verts[i] = input_verts[original_index];
}
else {
- BLI_assert(!"Unexpected new vertex in hull output");
+ BLI_assert_msg(0, "Unexpected new vertex in hull output");
}
}
diff --git a/source/blender/bmesh/tools/bmesh_bevel.c b/source/blender/bmesh/tools/bmesh_bevel.c
index 28d0aecbb3d..1e8ef9737d3 100644
--- a/source/blender/bmesh/tools/bmesh_bevel.c
+++ b/source/blender/bmesh/tools/bmesh_bevel.c
@@ -1676,7 +1676,7 @@ static void project_to_edge(const BMEdge *e,
float otherco[3];
if (!isect_line_line_v3(e->v1->co, e->v2->co, co_a, co_b, projco, otherco)) {
#ifdef BEVEL_ASSERT_PROJECT
- BLI_assert(!"project meet failure");
+ BLI_assert_msg(0, "project meet failure");
#endif
copy_v3_v3(projco, e->v1->co);
}
@@ -6262,7 +6262,7 @@ static BevVert *bevel_vert_construct(BMesh *bm, BevelParams *bp, BMVert *v)
break;
}
default: {
- BLI_assert(!"bad bevel offset kind");
+ BLI_assert_msg(0, "bad bevel offset kind");
e->offset_l_spec = bp->offset;
break;
}
diff --git a/source/blender/compositor/intern/COM_CompositorContext.cc b/source/blender/compositor/intern/COM_CompositorContext.cc
index 61e299c045e..a93820b66dc 100644
--- a/source/blender/compositor/intern/COM_CompositorContext.cc
+++ b/source/blender/compositor/intern/COM_CompositorContext.cc
@@ -53,7 +53,7 @@ eExecutionModel CompositorContext::get_execution_model() const
case 0:
return eExecutionModel::Tiled;
default:
- BLI_assert(!"Invalid execution mode");
+ BLI_assert_msg(0, "Invalid execution mode");
}
}
return eExecutionModel::Tiled;
diff --git a/source/blender/compositor/intern/COM_ConstantFolder.cc b/source/blender/compositor/intern/COM_ConstantFolder.cc
index a9427013f87..f20324de342 100644
--- a/source/blender/compositor/intern/COM_ConstantFolder.cc
+++ b/source/blender/compositor/intern/COM_ConstantFolder.cc
@@ -83,7 +83,7 @@ static ConstantOperation *create_constant_operation(DataType data_type, const fl
return value_op;
}
default: {
- BLI_assert(!"Non implemented data type");
+ BLI_assert_msg(0, "Non implemented data type");
return nullptr;
}
}
diff --git a/source/blender/compositor/intern/COM_ExecutionSystem.cc b/source/blender/compositor/intern/COM_ExecutionSystem.cc
index dfcf76cdd0a..60caf22be1b 100644
--- a/source/blender/compositor/intern/COM_ExecutionSystem.cc
+++ b/source/blender/compositor/intern/COM_ExecutionSystem.cc
@@ -79,7 +79,7 @@ ExecutionSystem::ExecutionSystem(RenderData *rd,
execution_model_ = new FullFrameExecutionModel(m_context, active_buffers_, m_operations);
break;
default:
- BLI_assert(!"Non implemented execution model");
+ BLI_assert_msg(0, "Non implemented execution model");
break;
}
}
diff --git a/source/blender/compositor/intern/COM_NodeOperation.cc b/source/blender/compositor/intern/COM_NodeOperation.cc
index 6484c75f364..4e115cb3f2f 100644
--- a/source/blender/compositor/intern/COM_NodeOperation.cc
+++ b/source/blender/compositor/intern/COM_NodeOperation.cc
@@ -218,7 +218,7 @@ void NodeOperation::get_area_of_interest(NodeOperation *input_op,
return;
}
}
- BLI_assert(!"input_op is not an input operation.");
+ BLI_assert_msg(0, "input_op is not an input operation.");
}
/**
diff --git a/source/blender/compositor/intern/COM_OpenCLDevice.cc b/source/blender/compositor/intern/COM_OpenCLDevice.cc
index 0f6ed0dbd2b..3409c8fa3bc 100644
--- a/source/blender/compositor/intern/COM_OpenCLDevice.cc
+++ b/source/blender/compositor/intern/COM_OpenCLDevice.cc
@@ -110,7 +110,7 @@ const cl_image_format *OpenCLDevice::determineImageFormat(MemoryBuffer *memoryBu
return &IMAGE_FORMAT_COLOR;
break;
default:
- BLI_assert(!"Unsupported num_channels.");
+ BLI_assert_msg(0, "Unsupported num_channels.");
}
return &IMAGE_FORMAT_COLOR;
diff --git a/source/blender/compositor/nodes/COM_RenderLayersNode.cc b/source/blender/compositor/nodes/COM_RenderLayersNode.cc
index 851d0366546..253ca542c04 100644
--- a/source/blender/compositor/nodes/COM_RenderLayersNode.cc
+++ b/source/blender/compositor/nodes/COM_RenderLayersNode.cc
@@ -107,7 +107,7 @@ void RenderLayersNode::testRenderLink(NodeConverter &converter,
type = DataType::Value;
break;
default:
- BLI_assert(!"Unexpected number of channels for pass");
+ BLI_assert_msg(0, "Unexpected number of channels for pass");
type = DataType::Value;
break;
}
diff --git a/source/blender/compositor/operations/COM_RenderLayersProg.cc b/source/blender/compositor/operations/COM_RenderLayersProg.cc
index 34fea705c75..72e2c92c9cf 100644
--- a/source/blender/compositor/operations/COM_RenderLayersProg.cc
+++ b/source/blender/compositor/operations/COM_RenderLayersProg.cc
@@ -163,7 +163,7 @@ void RenderLayersProg::executePixelSampled(float output[4], float x, float y, Pi
}
else {
expected_element_size = 0;
- BLI_assert(!"Something horribly wrong just happened");
+ BLI_assert_msg(0, "Something horribly wrong just happened");
}
BLI_assert(expected_element_size == actual_element_size);
}
diff --git a/source/blender/depsgraph/intern/builder/deg_builder.cc b/source/blender/depsgraph/intern/builder/deg_builder.cc
index f4d65698bee..41512168f57 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder.cc
@@ -97,7 +97,7 @@ bool DepsgraphBuilder::need_pull_base_into_graph(Base *base)
property_id = AnimatedPropertyID(&object->id, &RNA_Object, "hide_render");
}
else {
- BLI_assert(!"Unknown evaluation mode.");
+ BLI_assert_msg(0, "Unknown evaluation mode.");
return false;
}
return cache_->isPropertyAnimated(&object->id, property_id);
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
index bd3bc5d5ee7..e561d0b653c 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder_nodes.cc
@@ -227,7 +227,7 @@ OperationNode *DepsgraphNodeBuilder::add_operation_node(ComponentNode *comp_node
comp_node->identifier().c_str(),
op_node->identifier().c_str(),
op_node);
- BLI_assert(!"Should not happen!");
+ BLI_assert_msg(0, "Should not happen!");
}
return op_node;
}
@@ -1601,7 +1601,7 @@ void DepsgraphNodeBuilder::build_object_data_geometry_datablock(ID *obdata, bool
break;
}
default:
- BLI_assert(!"Should not happen");
+ BLI_assert_msg(0, "Should not happen");
break;
}
op_node = add_operation_node(obdata, NodeType::GEOMETRY, OperationCode::GEOMETRY_EVAL_DONE);
@@ -1780,7 +1780,7 @@ void DepsgraphNodeBuilder::build_nodetree(bNodeTree *ntree)
build_nodetree(group_ntree);
}
else {
- BLI_assert(!"Unknown ID type used for node");
+ BLI_assert_msg(0, "Unknown ID type used for node");
}
}
diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
index 5650e95f55a..415145c8fa1 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc
@@ -326,7 +326,7 @@ void DepsgraphRelationBuilder::add_customdata_mask(Object *object,
IDNode *id_node = graph_->find_id_node(&object->id);
if (id_node == nullptr) {
- BLI_assert(!"ID should always be valid");
+ BLI_assert_msg(0, "ID should always be valid");
}
else {
id_node->customdata_masks |= customdata_masks;
@@ -338,7 +338,7 @@ void DepsgraphRelationBuilder::add_special_eval_flag(ID *id, uint32_t flag)
{
IDNode *id_node = graph_->find_id_node(id);
if (id_node == nullptr) {
- BLI_assert(!"ID should always be valid");
+ BLI_assert_msg(0, "ID should always be valid");
}
else {
id_node->eval_flags |= flag;
@@ -2342,7 +2342,7 @@ void DepsgraphRelationBuilder::build_object_data_geometry_datablock(ID *obdata)
break;
}
default:
- BLI_assert(!"Should not happen");
+ BLI_assert_msg(0, "Should not happen");
break;
}
}
@@ -2525,7 +2525,7 @@ void DepsgraphRelationBuilder::build_nodetree(bNodeTree *ntree)
add_relation(group_shading_key, shading_key, "Group Node");
}
else {
- BLI_assert(!"Unknown ID type used for node");
+ BLI_assert_msg(0, "Unknown ID type used for node");
}
}
diff --git a/source/blender/depsgraph/intern/depsgraph.cc b/source/blender/depsgraph/intern/depsgraph.cc
index 076e15a3175..4c036417ba0 100644
--- a/source/blender/depsgraph/intern/depsgraph.cc
+++ b/source/blender/depsgraph/intern/depsgraph.cc
@@ -268,7 +268,7 @@ ID *Depsgraph::get_cow_id(const ID *id_orig) const
* - Object or mesh has material at a slot which is not used (for
* example, object has material slot by materials are set to
* object data). */
- // BLI_assert(!"Request for non-existing copy-on-write ID");
+ // BLI_assert_msg(0, "Request for non-existing copy-on-write ID");
}
return (ID *)id_orig;
}
diff --git a/source/blender/depsgraph/intern/depsgraph_debug.cc b/source/blender/depsgraph/intern/depsgraph_debug.cc
index c5e306f3148..3677f80469c 100644
--- a/source/blender/depsgraph/intern/depsgraph_debug.cc
+++ b/source/blender/depsgraph/intern/depsgraph_debug.cc
@@ -96,7 +96,7 @@ bool DEG_debug_graph_relations_validate(Depsgraph *graph,
DEG_graph_build_from_view_layer(temp_depsgraph);
if (!DEG_debug_compare(temp_depsgraph, graph)) {
fprintf(stderr, "ERROR! Depsgraph wasn't tagged for update when it should have!\n");
- BLI_assert(!"This should not happen!");
+ BLI_assert_msg(0, "This should not happen!");
valid = false;
}
DEG_graph_free(temp_depsgraph);
diff --git a/source/blender/depsgraph/intern/depsgraph_physics.cc b/source/blender/depsgraph/intern/depsgraph_physics.cc
index a2f914b1d89..a70c0c10de0 100644
--- a/source/blender/depsgraph/intern/depsgraph_physics.cc
+++ b/source/blender/depsgraph/intern/depsgraph_physics.cc
@@ -59,7 +59,7 @@ static ePhysicsRelationType modifier_to_relation_type(unsigned int modifier_type
return DEG_PHYSICS_DYNAMIC_BRUSH;
}
- BLI_assert(!"Unknown collision modifier type");
+ BLI_assert_msg(0, "Unknown collision modifier type");
return DEG_PHYSICS_RELATIONS_NUM;
}
/* Get ID from an ID type object, in a safe manner. This means that object can be nullptr,
diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cc b/source/blender/depsgraph/intern/depsgraph_tag.cc
index e879e8d0f23..34b33e9a6c0 100644
--- a/source/blender/depsgraph/intern/depsgraph_tag.cc
+++ b/source/blender/depsgraph/intern/depsgraph_tag.cc
@@ -238,7 +238,7 @@ void depsgraph_tag_to_component_opcode(const ID *id,
case ID_RECALC_GEOMETRY_ALL_MODES:
case ID_RECALC_ALL:
case ID_RECALC_PSYS_ALL:
- BLI_assert(!"Should not happen");
+ BLI_assert_msg(0, "Should not happen");
break;
case ID_RECALC_TAG_FOR_UNDO:
break; /* Must be ignored by depsgraph. */
@@ -457,7 +457,7 @@ const char *update_source_as_string(eUpdateSource source)
case DEG_UPDATE_SOURCE_VISIBILITY:
return "VISIBILITY";
}
- BLI_assert(!"Should never happen.");
+ BLI_assert_msg(0, "Should never happen.");
return "UNKNOWN";
}
diff --git a/source/blender/depsgraph/intern/eval/deg_eval.cc b/source/blender/depsgraph/intern/eval/deg_eval.cc
index 6f35143e28f..915b9fedcec 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval.cc
@@ -223,7 +223,7 @@ bool need_evaluate_operation_at_stage(DepsgraphEvalState *state,
case EvaluationStage::SINGLE_THREADED_WORKAROUND:
return true;
}
- BLI_assert(!"Unhandled evaluation stage, should never happen.");
+ BLI_assert_msg(0, "Unhandled evaluation stage, should never happen.");
return false;
}
diff --git a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
index 0d367762b00..346eba5bbc2 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
@@ -899,7 +899,7 @@ ID *deg_expand_copy_on_write_datablock(const Depsgraph *depsgraph,
done = id_copy_inplace_no_main(id_orig, id_cow);
}
if (!done) {
- BLI_assert(!"No idea how to perform CoW on datablock");
+ BLI_assert_msg(0, "No idea how to perform CoW on datablock");
}
/* Update pointers to nested ID datablocks. */
DEG_COW_PRINT(
diff --git a/source/blender/depsgraph/intern/node/deg_node.cc b/source/blender/depsgraph/intern/node/deg_node.cc
index 0d3563ee3de..fee5342df59 100644
--- a/source/blender/depsgraph/intern/node/deg_node.cc
+++ b/source/blender/depsgraph/intern/node/deg_node.cc
@@ -48,7 +48,7 @@ const char *nodeClassAsString(NodeClass node_class)
case NodeClass::OPERATION:
return "OPERATION";
}
- BLI_assert(!"Unhandled node class, should never happen.");
+ BLI_assert_msg(0, "Unhandled node class, should never happen.");
return "UNKNOWN";
}
@@ -121,7 +121,7 @@ const char *nodeTypeAsString(NodeType type)
case NodeType::NUM_TYPES:
return "SpecialCase";
}
- BLI_assert(!"Unhandled node type, should never happen.");
+ BLI_assert_msg(0, "Unhandled node type, should never happen.");
return "UNKNOWN";
}
@@ -177,7 +177,7 @@ eDepsSceneComponentType nodeTypeToSceneComponent(NodeType type)
case NodeType::SIMULATION:
return DEG_SCENE_COMP_PARAMETERS;
}
- BLI_assert(!"Unhandled node type, not suppsed to happen.");
+ BLI_assert_msg(0, "Unhandled node type, not suppsed to happen.");
return DEG_SCENE_COMP_PARAMETERS;
}
@@ -253,7 +253,7 @@ eDepsObjectComponentType nodeTypeToObjectComponent(NodeType type)
case NodeType::NUM_TYPES:
return DEG_OB_COMP_PARAMETERS;
}
- BLI_assert(!"Unhandled node type, not suppsed to happen.");
+ BLI_assert_msg(0, "Unhandled node type, not suppsed to happen.");
return DEG_OB_COMP_PARAMETERS;
}
diff --git a/source/blender/depsgraph/intern/node/deg_node_component.cc b/source/blender/depsgraph/intern/node/deg_node_component.cc
index 3573758805c..431bf536b65 100644
--- a/source/blender/depsgraph/intern/node/deg_node_component.cc
+++ b/source/blender/depsgraph/intern/node/deg_node_component.cc
@@ -142,7 +142,7 @@ OperationNode *ComponentNode::get_operation(OperationIDKey key) const
"%s: find_operation(%s) failed\n",
this->identifier().c_str(),
key.identifier().c_str());
- BLI_assert(!"Request for non-existing operation, should not happen");
+ BLI_assert_msg(0, "Request for non-existing operation, should not happen");
return nullptr;
}
return node;
@@ -190,7 +190,7 @@ OperationNode *ComponentNode::add_operation(const DepsEvalOperationCb &op,
this->identifier().c_str(),
op_node->identifier().c_str(),
op_node);
- BLI_assert(!"Should not happen!");
+ BLI_assert_msg(0, "Should not happen!");
}
/* attach extra data */
diff --git a/source/blender/depsgraph/intern/node/deg_node_id.cc b/source/blender/depsgraph/intern/node/deg_node_id.cc
index 688afe141e9..2b1ebc663fe 100644
--- a/source/blender/depsgraph/intern/node/deg_node_id.cc
+++ b/source/blender/depsgraph/intern/node/deg_node_id.cc
@@ -53,7 +53,7 @@ const char *linkedStateAsString(eDepsNode_LinkedState_Type linked_state)
case DEG_ID_LINKED_DIRECTLY:
return "DIRECTLY";
}
- BLI_assert(!"Unhandled linked state, should never happen.");
+ BLI_assert_msg(0, "Unhandled linked state, should never happen.");
return "UNKNOWN";
}
diff --git a/source/blender/depsgraph/intern/node/deg_node_operation.cc b/source/blender/depsgraph/intern/node/deg_node_operation.cc
index 62a3d65d1f4..d98486b83a8 100644
--- a/source/blender/depsgraph/intern/node/deg_node_operation.cc
+++ b/source/blender/depsgraph/intern/node/deg_node_operation.cc
@@ -211,7 +211,7 @@ const char *operationCodeAsString(OperationCode opcode)
case OperationCode::SIMULATION_EVAL:
return "SIMULATION_EVAL";
}
- BLI_assert(!"Unhandled operation code, should never happen.");
+ BLI_assert_msg(0, "Unhandled operation code, should never happen.");
return "UNKNOWN";
}
diff --git a/source/blender/draw/engines/eevee/eevee_engine.c b/source/blender/draw/engines/eevee/eevee_engine.c
index fa97ffb306b..9d4f7865c32 100644
--- a/source/blender/draw/engines/eevee/eevee_engine.c
+++ b/source/blender/draw/engines/eevee/eevee_engine.c
@@ -481,7 +481,7 @@ static void eevee_render_to_image(void *vedata,
time -= shuttertime;
break;
default:
- BLI_assert(!"Invalid motion blur position enum!");
+ BLI_assert_msg(0, "Invalid motion blur position enum!");
break;
}
diff --git a/source/blender/draw/engines/image/image_engine.c b/source/blender/draw/engines/image/image_engine.c
index b6fd73e76d1..395d50fbc6b 100644
--- a/source/blender/draw/engines/image/image_engine.c
+++ b/source/blender/draw/engines/image/image_engine.c
@@ -117,7 +117,7 @@ static void space_image_gpu_texture_get(Image *image,
const int sima_flag = sima->flag & ED_space_image_get_display_channel_mask(ibuf);
if (sima_flag & SI_SHOW_ZBUF && (ibuf->zbuf || ibuf->zbuf_float || (ibuf->channels == 1))) {
if (ibuf->zbuf) {
- BLI_assert(!"Integer based depth buffers not supported");
+ BLI_assert_msg(0, "Integer based depth buffers not supported");
}
else if (ibuf->zbuf_float) {
*r_gpu_texture = GPU_texture_create_2d(
diff --git a/source/blender/draw/engines/overlay/overlay_engine.c b/source/blender/draw/engines/overlay/overlay_engine.c
index 81b07b49784..235104245cc 100644
--- a/source/blender/draw/engines/overlay/overlay_engine.c
+++ b/source/blender/draw/engines/overlay/overlay_engine.c
@@ -200,7 +200,7 @@ static void OVERLAY_cache_init(void *vedata)
case CTX_MODE_OBJECT:
break;
default:
- BLI_assert(!"Draw mode invalid");
+ BLI_assert_msg(0, "Draw mode invalid");
break;
}
OVERLAY_antialiasing_cache_init(vedata);
diff --git a/source/blender/draw/engines/workbench/workbench_materials.c b/source/blender/draw/engines/workbench/workbench_materials.c
index 800d1085505..aaa1a5a6ff6 100644
--- a/source/blender/draw/engines/workbench/workbench_materials.c
+++ b/source/blender/draw/engines/workbench/workbench_materials.c
@@ -126,7 +126,7 @@ BLI_INLINE void workbench_material_get_image(
break;
}
default:
- BLI_assert(!"Node type not supported by workbench");
+ BLI_assert_msg(0, "Node type not supported by workbench");
}
}
}
diff --git a/source/blender/draw/intern/draw_cache_impl_particles.c b/source/blender/draw/intern/draw_cache_impl_particles.c
index 879b73eab27..5c51f24a435 100644
--- a/source/blender/draw/intern/draw_cache_impl_particles.c
+++ b/source/blender/draw/intern/draw_cache_impl_particles.c
@@ -1500,7 +1500,7 @@ static void particle_batch_cache_ensure_edit_pos_and_seg(PTCacheEdit *edit,
edit, particle, edit->pathcache, 0, edit->totcached, &elb, &data_step);
}
else {
- BLI_assert(!"Hairs are not in edit mode!");
+ BLI_assert_msg(0, "Hairs are not in edit mode!");
}
hair_cache->indices = GPU_indexbuf_build(&elb);
}
diff --git a/source/blender/draw/intern/draw_shader.c b/source/blender/draw/intern/draw_shader.c
index 9c756065353..121a0acd059 100644
--- a/source/blender/draw/intern/draw_shader.c
+++ b/source/blender/draw/intern/draw_shader.c
@@ -104,7 +104,7 @@ GPUShader *DRW_shader_hair_refine_get(ParticleRefineShader refinement,
sh = hair_refine_shader_transform_feedback_workaround_create(refinement);
break;
default:
- BLI_assert(!"Incorrect shader type");
+ BLI_assert_msg(0, "Incorrect shader type");
}
e_data.hair_refine_sh[refinement] = sh;
}
diff --git a/source/blender/editors/armature/pose_slide.c b/source/blender/editors/armature/pose_slide.c
index f01afcfc578..1a1685e4a01 100644
--- a/source/blender/editors/armature/pose_slide.c
+++ b/source/blender/editors/armature/pose_slide.c
@@ -833,7 +833,7 @@ static void pose_slide_apply_quat(tPoseSlideOp *pso, tPChanFCurveLink *pfl)
float prevFrameF, nextFrameF;
if (!pose_frame_range_from_object_get(pso, pfl->ob, &prevFrameF, &nextFrameF)) {
- BLI_assert(!"Invalid pfl data");
+ BLI_assert_msg(0, "Invalid pfl data");
return;
}
diff --git a/source/blender/editors/curve/editcurve_add.c b/source/blender/editors/curve/editcurve_add.c
index 065763764c1..2be55accd3a 100644
--- a/source/blender/editors/curve/editcurve_add.c
+++ b/source/blender/editors/curve/editcurve_add.c
@@ -485,7 +485,7 @@ Nurb *ED_curve_add_nurbs_primitive(
break;
default: /* should never happen */
- BLI_assert(!"invalid nurbs type");
+ BLI_assert_msg(0, "invalid nurbs type");
return NULL;
}
diff --git a/source/blender/editors/gpencil/gpencil_convert.c b/source/blender/editors/gpencil/gpencil_convert.c
index 2cb1e09d9a6..ee3536c2f3f 100644
--- a/source/blender/editors/gpencil/gpencil_convert.c
+++ b/source/blender/editors/gpencil/gpencil_convert.c
@@ -1409,7 +1409,7 @@ static void gpencil_layer_to_curve(bContext *C,
gtd);
break;
default:
- BLI_assert(!"invalid mode");
+ BLI_assert_msg(0, "invalid mode");
break;
}
prev_gps = gps;
diff --git a/source/blender/editors/gpencil/gpencil_select.c b/source/blender/editors/gpencil/gpencil_select.c
index c33b43247fd..69734fa1ba8 100644
--- a/source/blender/editors/gpencil/gpencil_select.c
+++ b/source/blender/editors/gpencil/gpencil_select.c
@@ -689,7 +689,7 @@ static int gpencil_select_grouped_exec(bContext *C, wmOperator *op)
break;
default:
- BLI_assert(!"unhandled select grouped gpencil mode");
+ BLI_assert_msg(0, "unhandled select grouped gpencil mode");
break;
}
diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c
index 0e45970a165..3136ca64e0f 100644
--- a/source/blender/editors/interface/interface_handlers.c
+++ b/source/blender/editors/interface/interface_handlers.c
@@ -6513,7 +6513,7 @@ static void ui_ndofedit_but_HSVCUBE(uiButHSVCube *hsv_but,
CLAMP(hsv[2], hsv_but->but.softmin, hsv_but->but.softmax);
break;
default:
- BLI_assert(!"invalid hsv type");
+ BLI_assert_msg(0, "invalid hsv type");
break;
}
diff --git a/source/blender/editors/interface/interface_icons.c b/source/blender/editors/interface/interface_icons.c
index aa957afbf8f..2a505abe257 100644
--- a/source/blender/editors/interface/interface_icons.c
+++ b/source/blender/editors/interface/interface_icons.c
@@ -1500,7 +1500,7 @@ static void icon_draw_rect(float x,
/* sanity check */
if (w <= 0 || h <= 0 || w > 2000 || h > 2000) {
printf("%s: icons are %i x %i pixels?\n", __func__, w, h);
- BLI_assert(!"invalid icon size");
+ BLI_assert_msg(0, "invalid icon size");
return;
}
/* modulate color */
diff --git a/source/blender/editors/interface/interface_widgets.c b/source/blender/editors/interface/interface_widgets.c
index 72847fb2476..8abff4ad0d8 100644
--- a/source/blender/editors/interface/interface_widgets.c
+++ b/source/blender/editors/interface/interface_widgets.c
@@ -3115,7 +3115,7 @@ void ui_draw_gradient(const rcti *rect,
copy_v3_v3(col1[3], col1[2]);
break;
default:
- BLI_assert(!"invalid 'type' argument");
+ BLI_assert_msg(0, "invalid 'type' argument");
hsv_to_rgb(1.0, 1.0, 1.0, &col1[2][0], &col1[2][1], &col1[2][2]);
copy_v3_v3(col1[0], col1[2]);
copy_v3_v3(col1[1], col1[2]);
@@ -5374,7 +5374,7 @@ void ui_draw_menu_item(const uiFontStyle *fstyle,
}
}
else {
- BLI_assert(!"Unknwon menu item separator type");
+ BLI_assert_msg(0, "Unknwon menu item separator type");
}
if (fstyle->kerning == 1) {
diff --git a/source/blender/editors/interface/view2d_edge_pan.c b/source/blender/editors/interface/view2d_edge_pan.c
index ca32a754f1d..1d300c7b275 100644
--- a/source/blender/editors/interface/view2d_edge_pan.c
+++ b/source/blender/editors/interface/view2d_edge_pan.c
@@ -160,7 +160,7 @@ static float edge_pan_speed(View2DEdgePanData *vpd,
distance = min - event_loc;
}
else {
- BLI_assert(!"Calculating speed outside of pan zones");
+ BLI_assert_msg(0, "Calculating speed outside of pan zones");
return 0.0f;
}
float distance_factor = distance / (vpd->speed_ramp * U.widget_unit);
diff --git a/source/blender/editors/mask/mask_ops.c b/source/blender/editors/mask/mask_ops.c
index 3476f1ca735..6fa7457ce14 100644
--- a/source/blender/editors/mask/mask_ops.c
+++ b/source/blender/editors/mask/mask_ops.c
@@ -390,7 +390,7 @@ static void select_sliding_point(Mask *mask,
point->bezt.f3 |= SELECT;
break;
default:
- BLI_assert(!"Unexpected situation in select_sliding_point()");
+ BLI_assert_msg(0, "Unexpected situation in select_sliding_point()");
}
mask_layer->act_spline = spline;
diff --git a/source/blender/editors/object/object_relations.c b/source/blender/editors/object/object_relations.c
index d7177eabcba..c61965b3e23 100644
--- a/source/blender/editors/object/object_relations.c
+++ b/source/blender/editors/object/object_relations.c
@@ -2022,7 +2022,7 @@ static void single_obdata_users(
break;
default:
printf("ERROR %s: can't copy %s\n", __func__, id->name);
- BLI_assert(!"This should never happen.");
+ BLI_assert_msg(0, "This should never happen.");
/* We need to end the FOREACH_OBJECT_FLAG_BEGIN iterator to prevent memory leak. */
BKE_scene_objects_iterator_end(&iter_macro);
diff --git a/source/blender/editors/render/render_preview.c b/source/blender/editors/render/render_preview.c
index e8f69aded5b..7f7ee45a803 100644
--- a/source/blender/editors/render/render_preview.c
+++ b/source/blender/editors/render/render_preview.c
@@ -253,7 +253,7 @@ static const char *preview_collection_name(const char pr_type)
case MA_ATMOS:
return "Atmosphere";
default:
- BLI_assert(!"Unknown preview type");
+ BLI_assert_msg(0, "Unknown preview type");
return "";
}
}
@@ -335,7 +335,7 @@ static ID *duplicate_ids(ID *id, const bool allow_failure)
return NULL;
default:
if (!allow_failure) {
- BLI_assert(!"ID type preview not supported.");
+ BLI_assert_msg(0, "ID type preview not supported.");
}
return NULL;
}
@@ -1469,7 +1469,7 @@ static int icon_previewimg_size_index_get(const IconPreviewSize *icon_size,
}
}
- BLI_assert(!"The searched icon size does not match any in the preview image");
+ BLI_assert_msg(0, "The searched icon size does not match any in the preview image");
return -1;
}
diff --git a/source/blender/editors/render/render_shading.c b/source/blender/editors/render/render_shading.c
index 9595a66173b..d2b1ebdad78 100644
--- a/source/blender/editors/render/render_shading.c
+++ b/source/blender/editors/render/render_shading.c
@@ -2418,7 +2418,7 @@ static void paste_mtex_copybuf(ID *id)
mtex = &(((FreestyleLineStyle *)id)->mtex[(int)((FreestyleLineStyle *)id)->texact]);
break;
default:
- BLI_assert(!"invalid id type");
+ BLI_assert_msg(0, "invalid id type");
return;
}
diff --git a/source/blender/editors/screen/area.c b/source/blender/editors/screen/area.c
index 39de63c22a9..f4109981aae 100644
--- a/source/blender/editors/screen/area.c
+++ b/source/blender/editors/screen/area.c
@@ -3672,7 +3672,7 @@ static void region_visible_rect_calc(ARegion *region, rcti *rect)
/* Skip floating. */
}
else {
- BLI_assert(!"Region overlap with unknown alignment");
+ BLI_assert_msg(0, "Region overlap with unknown alignment");
}
}
}
diff --git a/source/blender/editors/screen/area_query.c b/source/blender/editors/screen/area_query.c
index d569e56e11b..fd4f3964398 100644
--- a/source/blender/editors/screen/area_query.c
+++ b/source/blender/editors/screen/area_query.c
@@ -88,7 +88,7 @@ bool ED_region_panel_category_gutter_calc_rect(const ARegion *region, rcti *r_re
r_region_gutter->xmin = r_region_gutter->xmax - category_tabs_width;
}
else {
- BLI_assert(!"Unsupported alignment");
+ BLI_assert_msg(0, "Unsupported alignment");
}
return true;
}
diff --git a/source/blender/editors/screen/glutil.c b/source/blender/editors/screen/glutil.c
index e366760a55d..f651fd4fb61 100644
--- a/source/blender/editors/screen/glutil.c
+++ b/source/blender/editors/screen/glutil.c
@@ -126,7 +126,7 @@ void immDrawPixelsTexScaled_clipping(IMMDrawPixelsTexState *state,
components = 1;
}
else {
- BLI_assert(!"Incompatible format passed to immDrawPixels");
+ BLI_assert_msg(0, "Incompatible format passed to immDrawPixels");
return;
}
@@ -426,7 +426,7 @@ void ED_draw_imbuf_clipping(ImBuf *ibuf,
format = GPU_RGBA16F;
}
else {
- BLI_assert(!"Incompatible number of channels for GLSL display");
+ BLI_assert_msg(0, "Incompatible number of channels for GLSL display");
}
if (format != 0) {
diff --git a/source/blender/editors/sculpt_paint/sculpt.c b/source/blender/editors/sculpt_paint/sculpt.c
index 54b6f3d3590..83388c1aef2 100644
--- a/source/blender/editors/sculpt_paint/sculpt.c
+++ b/source/blender/editors/sculpt_paint/sculpt.c
@@ -2394,7 +2394,7 @@ static float brush_strength(const Sculpt *sd,
case BRUSH_MASK_SMOOTH:
return alpha * pressure * feather;
}
- BLI_assert(!"Not supposed to happen");
+ BLI_assert_msg(0, "Not supposed to happen");
return 0.0f;
case SCULPT_TOOL_CREASE:
diff --git a/source/blender/editors/sculpt_paint/sculpt_automasking.c b/source/blender/editors/sculpt_paint/sculpt_automasking.c
index 5f5fb51d75f..35f48400fe2 100644
--- a/source/blender/editors/sculpt_paint/sculpt_automasking.c
+++ b/source/blender/editors/sculpt_paint/sculpt_automasking.c
@@ -209,7 +209,7 @@ static float *SCULPT_topology_automasking_init(Sculpt *sd, Object *ob, float *au
Brush *brush = BKE_paint_brush(&sd->paint);
if (BKE_pbvh_type(ss->pbvh) == PBVH_FACES && !ss->pmap) {
- BLI_assert(!"Topology masking: pmap missing");
+ BLI_assert_msg(0, "Topology masking: pmap missing");
return NULL;
}
@@ -248,7 +248,7 @@ static float *sculpt_face_sets_automasking_init(Sculpt *sd, Object *ob, float *a
}
if (BKE_pbvh_type(ss->pbvh) == PBVH_FACES && !ss->pmap) {
- BLI_assert(!"Face Sets automasking: pmap missing");
+ BLI_assert_msg(0, "Face Sets automasking: pmap missing");
return NULL;
}
@@ -273,7 +273,7 @@ float *SCULPT_boundary_automasking_init(Object *ob,
SculptSession *ss = ob->sculpt;
if (!ss->pmap) {
- BLI_assert(!"Boundary Edges masking: pmap missing");
+ BLI_assert_msg(0, "Boundary Edges masking: pmap missing");
return NULL;
}
diff --git a/source/blender/editors/sculpt_paint/sculpt_smooth.c b/source/blender/editors/sculpt_paint/sculpt_smooth.c
index 61984610a5a..eabbfe43e03 100644
--- a/source/blender/editors/sculpt_paint/sculpt_smooth.c
+++ b/source/blender/editors/sculpt_paint/sculpt_smooth.c
@@ -367,7 +367,7 @@ void SCULPT_smooth(Sculpt *sd,
last = max_iterations * (bstrength - count * fract);
if (type == PBVH_FACES && !ss->pmap) {
- BLI_assert(!"sculpt smooth: pmap missing");
+ BLI_assert_msg(0, "sculpt smooth: pmap missing");
return;
}
diff --git a/source/blender/editors/sculpt_paint/sculpt_undo.c b/source/blender/editors/sculpt_paint/sculpt_undo.c
index f21c900941b..501a1e53276 100644
--- a/source/blender/editors/sculpt_paint/sculpt_undo.c
+++ b/source/blender/editors/sculpt_paint/sculpt_undo.c
@@ -766,7 +766,7 @@ static void sculpt_undo_restore_list(bContext *C, Depsgraph *depsgraph, ListBase
case SCULPT_UNDO_DYNTOPO_BEGIN:
case SCULPT_UNDO_DYNTOPO_END:
case SCULPT_UNDO_DYNTOPO_SYMMETRIZE:
- BLI_assert(!"Dynamic topology should've already been handled");
+ BLI_assert_msg(0, "Dynamic topology should've already been handled");
break;
}
}
@@ -1065,7 +1065,7 @@ static SculptUndoNode *sculpt_undo_alloc_node(Object *ob, PBVHNode *node, Sculpt
case SCULPT_UNDO_DYNTOPO_BEGIN:
case SCULPT_UNDO_DYNTOPO_END:
case SCULPT_UNDO_DYNTOPO_SYMMETRIZE:
- BLI_assert(!"Dynamic topology should've already been handled");
+ BLI_assert_msg(0, "Dynamic topology should've already been handled");
case SCULPT_UNDO_GEOMETRY:
case SCULPT_UNDO_FACE_SETS:
break;
@@ -1355,7 +1355,7 @@ SculptUndoNode *SCULPT_undo_push_node(Object *ob, PBVHNode *node, SculptUndoType
case SCULPT_UNDO_DYNTOPO_BEGIN:
case SCULPT_UNDO_DYNTOPO_END:
case SCULPT_UNDO_DYNTOPO_SYMMETRIZE:
- BLI_assert(!"Dynamic topology should've already been handled");
+ BLI_assert_msg(0, "Dynamic topology should've already been handled");
case SCULPT_UNDO_GEOMETRY:
case SCULPT_UNDO_FACE_SETS:
break;
diff --git a/source/blender/editors/space_clip/clip_editor.c b/source/blender/editors/space_clip/clip_editor.c
index 2da13646a8b..67b4fd61d38 100644
--- a/source/blender/editors/space_clip/clip_editor.c
+++ b/source/blender/editors/space_clip/clip_editor.c
@@ -1025,7 +1025,7 @@ static void prefetch_startjob(void *pjv, short *stop, short *do_update, float *p
progress);
}
else {
- BLI_assert(!"Unknown movie clip source when prefetching frames");
+ BLI_assert_msg(0, "Unknown movie clip source when prefetching frames");
}
}
diff --git a/source/blender/editors/space_file/filesel.c b/source/blender/editors/space_file/filesel.c
index b7accbf71e5..7ab93df81d2 100644
--- a/source/blender/editors/space_file/filesel.c
+++ b/source/blender/editors/space_file/filesel.c
@@ -378,7 +378,7 @@ FileSelectParams *ED_fileselect_ensure_active_params(SpaceFile *sfile)
return &sfile->asset_params->base_params;
}
- BLI_assert(!"Invalid browse mode set in file space.");
+ BLI_assert_msg(0, "Invalid browse mode set in file space.");
return NULL;
}
@@ -399,7 +399,7 @@ FileSelectParams *ED_fileselect_get_active_params(const SpaceFile *sfile)
return (FileSelectParams *)sfile->asset_params;
}
- BLI_assert(!"Invalid browse mode set in file space.");
+ BLI_assert_msg(0, "Invalid browse mode set in file space.");
return NULL;
}
diff --git a/source/blender/editors/space_outliner/outliner_tree.c b/source/blender/editors/space_outliner/outliner_tree.c
index c08707b7a6a..c5ec656080a 100644
--- a/source/blender/editors/space_outliner/outliner_tree.c
+++ b/source/blender/editors/space_outliner/outliner_tree.c
@@ -592,7 +592,7 @@ static void outliner_add_id_contents(SpaceOutliner *space_outliner,
switch (GS(id->name)) {
case ID_LI:
case ID_SCE:
- BLI_assert(!"ID type expected to be expanded through new tree-element design");
+ BLI_assert_msg(0, "ID type expected to be expanded through new tree-element design");
break;
case ID_OB: {
outliner_add_object_contents(space_outliner, te, tselem, (Object *)id);
@@ -905,12 +905,13 @@ TreeElement *outliner_add_element(SpaceOutliner *space_outliner,
}
else if (type == TSE_SOME_ID) {
if (!te->type) {
- BLI_assert(!"Expected this ID type to be ported to new Outliner tree-element design");
+ BLI_assert_msg(0, "Expected this ID type to be ported to new Outliner tree-element design");
}
}
else if (ELEM(type, TSE_LIBRARY_OVERRIDE_BASE, TSE_LIBRARY_OVERRIDE)) {
if (!te->type) {
- BLI_assert(!"Expected override types to be ported to new Outliner tree-element design");
+ BLI_assert_msg(0,
+ "Expected override types to be ported to new Outliner tree-element design");
}
}
else {
diff --git a/source/blender/editors/space_outliner/tree/tree_element_id.cc b/source/blender/editors/space_outliner/tree/tree_element_id.cc
index ce99b954204..7ff5a3285f1 100644
--- a/source/blender/editors/space_outliner/tree/tree_element_id.cc
+++ b/source/blender/editors/space_outliner/tree/tree_element_id.cc
@@ -85,7 +85,7 @@ TreeElementID *TreeElementID::createFromID(TreeElement &legacy_te, ID &id)
return new TreeElementID(legacy_te, id);
/* Deprecated */
case ID_IP:
- BLI_assert(!"Outliner trying to build tree-element for deprecated ID type");
+ BLI_assert_msg(0, "Outliner trying to build tree-element for deprecated ID type");
return nullptr;
}
diff --git a/source/blender/editors/space_sequencer/sequencer_draw.c b/source/blender/editors/space_sequencer/sequencer_draw.c
index 8371a634a78..cdbe5bc63ce 100644
--- a/source/blender/editors/space_sequencer/sequencer_draw.c
+++ b/source/blender/editors/space_sequencer/sequencer_draw.c
@@ -1556,7 +1556,7 @@ static void *sequencer_OCIO_transform_ibuf(const bContext *C,
*r_format = GPU_RGB16F;
}
else {
- BLI_assert(!"Incompatible number of channels for float buffer in sequencer");
+ BLI_assert_msg(0, "Incompatible number of channels for float buffer in sequencer");
*r_format = GPU_RGBA16F;
display_buffer = NULL;
}
diff --git a/source/blender/editors/space_view3d/view3d_select.c b/source/blender/editors/space_view3d/view3d_select.c
index 210dd7311a4..ecf43c734e2 100644
--- a/source/blender/editors/space_view3d/view3d_select.c
+++ b/source/blender/editors/space_view3d/view3d_select.c
@@ -1378,7 +1378,7 @@ static bool view3d_lasso_select(bContext *C,
changed = do_lasso_select_meta(vc, mcoords, mcoords_len, sel_op);
break;
default:
- BLI_assert(!"lasso select on incorrect object type");
+ BLI_assert_msg(0, "lasso select on incorrect object type");
break;
}
@@ -3604,7 +3604,7 @@ static int view3d_box_select_exec(bContext *C, wmOperator *op)
}
break;
default:
- BLI_assert(!"box select on incorrect object type");
+ BLI_assert_msg(0, "box select on incorrect object type");
break;
}
changed_multi |= changed;
diff --git a/source/blender/editors/transform/transform_generics.c b/source/blender/editors/transform/transform_generics.c
index 575d9c0828e..aaac8e21cb9 100644
--- a/source/blender/editors/transform/transform_generics.c
+++ b/source/blender/editors/transform/transform_generics.c
@@ -910,7 +910,7 @@ void calculateCenterCursor2D(TransInfo *t, float r_center[2])
BKE_mask_coord_from_movieclip(space_clip->clip, &space_clip->user, co, cursor);
}
else {
- BLI_assert(!"Shall not happen");
+ BLI_assert_msg(0, "Shall not happen");
}
r_center[0] = co[0] * t->aspect[0];
diff --git a/source/blender/editors/transform/transform_mode_edge_slide.c b/source/blender/editors/transform/transform_mode_edge_slide.c
index bdd074666a2..066a2853dc7 100644
--- a/source/blender/editors/transform/transform_mode_edge_slide.c
+++ b/source/blender/editors/transform/transform_mode_edge_slide.c
@@ -107,7 +107,7 @@ static TransDataContainer *edge_slide_container_first_ok(TransInfo *t)
return tc;
}
}
- BLI_assert(!"Should never happen, at least one EdgeSlideData should be valid");
+ BLI_assert_msg(0, "Should never happen, at least one EdgeSlideData should be valid");
return NULL;
}
diff --git a/source/blender/editors/undo/ed_undo.c b/source/blender/editors/undo/ed_undo.c
index 00efdb87fea..23161028e03 100644
--- a/source/blender/editors/undo/ed_undo.c
+++ b/source/blender/editors/undo/ed_undo.c
@@ -321,7 +321,7 @@ static int ed_undo_step_by_name(bContext *C, const char *undo_name, ReportList *
/* FIXME: See comments in `ed_undo_step_direction`. */
if (ED_gpencil_session_active()) {
- BLI_assert(!"Not implemented currently.");
+ BLI_assert_msg(0, "Not implemented currently.");
}
wmWindowManager *wm = CTX_wm_manager(C);
@@ -369,7 +369,7 @@ static int ed_undo_step_by_index(bContext *C, const int undo_index, ReportList *
/* FIXME: See comments in `ed_undo_step_direction`. */
if (ED_gpencil_session_active()) {
- BLI_assert(!"Not implemented currently.");
+ BLI_assert_msg(0, "Not implemented currently.");
}
wmWindowManager *wm = CTX_wm_manager(C);
diff --git a/source/blender/editors/util/select_utils.c b/source/blender/editors/util/select_utils.c
index 4e8cf1e92e6..5681edd2f5c 100644
--- a/source/blender/editors/util/select_utils.c
+++ b/source/blender/editors/util/select_utils.c
@@ -41,7 +41,7 @@ int ED_select_op_action(const eSelectOp sel_op, const bool is_select, const bool
case SEL_OP_XOR:
return (is_select && is_inside) ? 0 : ((!is_select && is_inside) ? 1 : -1);
}
- BLI_assert(!"invalid sel_op");
+ BLI_assert_msg(0, "invalid sel_op");
return -1;
}
/**
@@ -67,7 +67,7 @@ int ED_select_op_action_deselected(const eSelectOp sel_op,
case SEL_OP_XOR:
return (is_select && is_inside) ? 0 : ((!is_select && is_inside) ? 1 : -1);
}
- BLI_assert(!"invalid sel_op");
+ BLI_assert_msg(0, "invalid sel_op");
return -1;
}
diff --git a/source/blender/gpu/intern/gpu_node_graph.c b/source/blender/gpu/intern/gpu_node_graph.c
index dad03ab22e5..7646cce2a3e 100644
--- a/source/blender/gpu/intern/gpu_node_graph.c
+++ b/source/blender/gpu/intern/gpu_node_graph.c
@@ -174,7 +174,7 @@ static const char *gpu_uniform_set_function_from_type(eNodeSocketDatatype type)
case SOCK_RGBA:
return "set_rgba";
default:
- BLI_assert(!"No gpu function for non-supported eNodeSocketDatatype");
+ BLI_assert_msg(0, "No gpu function for non-supported eNodeSocketDatatype");
return NULL;
}
}
diff --git a/source/blender/gpu/intern/gpu_texture.cc b/source/blender/gpu/intern/gpu_texture.cc
index f7a4d672b02..6564cbda694 100644
--- a/source/blender/gpu/intern/gpu_texture.cc
+++ b/source/blender/gpu/intern/gpu_texture.cc
@@ -154,7 +154,7 @@ void Texture::attach_to(FrameBuffer *fb, GPUAttachmentType type)
return;
}
}
- BLI_assert(!"GPU: Error: Texture: Not enough attachment");
+ BLI_assert_msg(0, "GPU: Error: Texture: Not enough attachment");
}
void Texture::detach_from(FrameBuffer *fb)
@@ -166,7 +166,7 @@ void Texture::detach_from(FrameBuffer *fb)
return;
}
}
- BLI_assert(!"GPU: Error: Texture: Framebuffer is not attached");
+ BLI_assert_msg(0, "GPU: Error: Texture: Framebuffer is not attached");
}
void Texture::update(eGPUDataFormat format, const void *data)
diff --git a/source/blender/gpu/intern/gpu_uniform_buffer.cc b/source/blender/gpu/intern/gpu_uniform_buffer.cc
index 3edb090d81c..3a9269d1753 100644
--- a/source/blender/gpu/intern/gpu_uniform_buffer.cc
+++ b/source/blender/gpu/intern/gpu_uniform_buffer.cc
@@ -114,11 +114,11 @@ static void buffer_from_list_inputs_sort(ListBase *inputs)
if (input->type == GPU_MAT3) {
/* Alignment for mat3 is not handled currently, so not supported */
- BLI_assert(!"mat3 not supported in UBO");
+ BLI_assert_msg(0, "mat3 not supported in UBO");
continue;
}
if (input->type > MAX_UBO_GPU_TYPE) {
- BLI_assert(!"GPU type not supported in UBO");
+ BLI_assert_msg(0, "GPU type not supported in UBO");
continue;
}
diff --git a/source/blender/gpu/intern/gpu_viewport.c b/source/blender/gpu/intern/gpu_viewport.c
index ddf31b6ffa7..96bf1ec40b0 100644
--- a/source/blender/gpu/intern/gpu_viewport.c
+++ b/source/blender/gpu/intern/gpu_viewport.c
@@ -248,7 +248,7 @@ void *GPU_viewport_engine_data_create(GPUViewport *viewport, void *engine_type)
}
}
- BLI_assert(!"Too many draw engines enabled at the same time");
+ BLI_assert_msg(0, "Too many draw engines enabled at the same time");
return NULL;
}
diff --git a/source/blender/gpu/opengl/gl_framebuffer.cc b/source/blender/gpu/opengl/gl_framebuffer.cc
index e87b22985bd..8da114d9270 100644
--- a/source/blender/gpu/opengl/gl_framebuffer.cc
+++ b/source/blender/gpu/opengl/gl_framebuffer.cc
@@ -268,7 +268,7 @@ void GLFrameBuffer::bind(bool enabled_srgb)
}
if (context_ != GLContext::get()) {
- BLI_assert(!"Trying to use the same frame-buffer in multiple context");
+ BLI_assert_msg(0, "Trying to use the same frame-buffer in multiple context");
return;
}
@@ -379,7 +379,7 @@ void GLFrameBuffer::clear_attachment(GPUAttachmentType type,
glClearBufferfv(GL_DEPTH, 0, &depth);
}
else {
- BLI_assert(!"Unhandled data format");
+ BLI_assert_msg(0, "Unhandled data format");
}
}
else {
@@ -395,7 +395,7 @@ void GLFrameBuffer::clear_attachment(GPUAttachmentType type,
glClearBufferiv(GL_COLOR, slot, (GLint *)clear_value);
break;
default:
- BLI_assert(!"Unhandled data format");
+ BLI_assert_msg(0, "Unhandled data format");
break;
}
}
diff --git a/source/blender/imbuf/intern/colormanagement.c b/source/blender/imbuf/intern/colormanagement.c
index 71e513fb405..2cc44ebc67b 100644
--- a/source/blender/imbuf/intern/colormanagement.c
+++ b/source/blender/imbuf/intern/colormanagement.c
@@ -1542,7 +1542,7 @@ static void display_buffer_apply_get_linear_buffer(DisplayBufferThread *handle,
rgba_uchar_to_float(fp, cp);
}
else {
- BLI_assert(!"Buffers of 3 or 4 channels are only supported here");
+ BLI_assert_msg(0, "Buffers of 3 or 4 channels are only supported here");
}
}
@@ -3437,7 +3437,7 @@ static void partial_buffer_update_rect(ImBuf *ibuf,
pixel[0] = linear_buffer[linear_index];
}
else {
- BLI_assert(!"Unsupported number of channels in partial buffer update");
+ BLI_assert_msg(0, "Unsupported number of channels in partial buffer update");
}
}
else if (byte_buffer) {
diff --git a/source/blender/imbuf/intern/indexer.c b/source/blender/imbuf/intern/indexer.c
index 71137a408d2..27195b294d6 100644
--- a/source/blender/imbuf/intern/indexer.c
+++ b/source/blender/imbuf/intern/indexer.c
@@ -357,7 +357,7 @@ int IMB_proxy_size_to_array_index(IMB_Proxy_Size pr_size)
case IMB_PROXY_100:
return 3;
default:
- BLI_assert(!"Unhandled proxy size enum!");
+ BLI_assert_msg(0, "Unhandled proxy size enum!");
return -1;
}
}
@@ -376,7 +376,7 @@ int IMB_timecode_to_array_index(IMB_Timecode_Type tc)
case IMB_TC_RECORD_RUN_NO_GAPS:
return 3;
default:
- BLI_assert(!"Unhandled timecode type enum!");
+ BLI_assert_msg(0, "Unhandled timecode type enum!");
return -1;
}
}
diff --git a/source/blender/io/alembic/exporter/abc_custom_props.cc b/source/blender/io/alembic/exporter/abc_custom_props.cc
index f5593e7ee30..4ea2fd03fff 100644
--- a/source/blender/io/alembic/exporter/abc_custom_props.cc
+++ b/source/blender/io/alembic/exporter/abc_custom_props.cc
@@ -141,7 +141,7 @@ void CustomPropertiesExporter::write_idparray(const IDProperty *idp_array)
continue;
}
std::cerr << "Custom property " << idp_array->name << " has elements of varying type";
- BLI_assert(!"Mixed type IDP_ARRAY custom property found");
+ BLI_assert_msg(0, "Mixed type IDP_ARRAY custom property found");
}
#endif
diff --git a/source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc b/source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc
index e2be241c144..174b2abb90f 100644
--- a/source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc
+++ b/source/blender/io/alembic/exporter/abc_hierarchy_iterator.cc
@@ -229,7 +229,7 @@ ABCAbstractWriter *ABCHierarchyIterator::create_data_writer_for_object_type(
case OB_GPENCIL:
return nullptr;
case OB_TYPE_MAX:
- BLI_assert(!"OB_TYPE_MAX should not be used");
+ BLI_assert_msg(0, "OB_TYPE_MAX should not be used");
return nullptr;
}
diff --git a/source/blender/io/alembic/exporter/abc_writer_instance.cc b/source/blender/io/alembic/exporter/abc_writer_instance.cc
index 1737e8c091e..353705f2c1d 100644
--- a/source/blender/io/alembic/exporter/abc_writer_instance.cc
+++ b/source/blender/io/alembic/exporter/abc_writer_instance.cc
@@ -59,7 +59,7 @@ Alembic::Abc::OCompoundProperty ABCInstanceWriter::abc_prop_for_custom_props()
OObject ABCInstanceWriter::get_alembic_object() const
{
/* There is no OObject for an instance. */
- BLI_assert(!"ABCInstanceWriter cannot return its Alembic OObject");
+ BLI_assert_msg(0, "ABCInstanceWriter cannot return its Alembic OObject");
return OObject();
}
diff --git a/source/blender/io/usd/intern/usd_hierarchy_iterator.cc b/source/blender/io/usd/intern/usd_hierarchy_iterator.cc
index 66dfc21441e..a9cba7f36d9 100644
--- a/source/blender/io/usd/intern/usd_hierarchy_iterator.cc
+++ b/source/blender/io/usd/intern/usd_hierarchy_iterator.cc
@@ -121,7 +121,7 @@ AbstractHierarchyWriter *USDHierarchyIterator::create_data_writer(const Hierarch
case OB_GPENCIL:
return nullptr;
case OB_TYPE_MAX:
- BLI_assert(!"OB_TYPE_MAX should not be used");
+ BLI_assert_msg(0, "OB_TYPE_MAX should not be used");
return nullptr;
}
diff --git a/source/blender/io/usd/intern/usd_writer_abstract.cc b/source/blender/io/usd/intern/usd_writer_abstract.cc
index 5e66136abf1..6965ecf6249 100644
--- a/source/blender/io/usd/intern/usd_writer_abstract.cc
+++ b/source/blender/io/usd/intern/usd_writer_abstract.cc
@@ -128,7 +128,7 @@ bool USDAbstractWriter::mark_as_instance(const HierarchyContext &context, const
if (context.export_path == context.original_export_path) {
printf("USD ref error: export path is reference path: %s\n", context.export_path.c_str());
- BLI_assert(!"USD reference error");
+ BLI_assert_msg(0, "USD reference error");
return false;
}
diff --git a/source/blender/io/usd/intern/usd_writer_camera.cc b/source/blender/io/usd/intern/usd_writer_camera.cc
index 677be9a7fc4..50d644241df 100644
--- a/source/blender/io/usd/intern/usd_writer_camera.cc
+++ b/source/blender/io/usd/intern/usd_writer_camera.cc
@@ -61,7 +61,7 @@ static void camera_sensor_size_for_render(const Camera *camera,
*r_sensor_y = camera->sensor_y;
break;
case CAMERA_SENSOR_FIT_AUTO:
- BLI_assert(!"Camera fit should be either horizontal or vertical");
+ BLI_assert_msg(0, "Camera fit should be either horizontal or vertical");
break;
}
}
diff --git a/source/blender/io/usd/intern/usd_writer_light.cc b/source/blender/io/usd/intern/usd_writer_light.cc
index f77c51c22ec..7ffae1dd398 100644
--- a/source/blender/io/usd/intern/usd_writer_light.cc
+++ b/source/blender/io/usd/intern/usd_writer_light.cc
@@ -87,7 +87,7 @@ void USDLightWriter::do_write(HierarchyContext &context)
usd_light = pxr::UsdLuxDistantLight::Define(stage, usd_path);
break;
default:
- BLI_assert(!"is_supported() returned true for unsupported light type");
+ BLI_assert_msg(0, "is_supported() returned true for unsupported light type");
}
/* Scale factor to get to somewhat-similar illumination. Since the USDViewer had similar
diff --git a/source/blender/makesdna/intern/dna_genfile.c b/source/blender/makesdna/intern/dna_genfile.c
index 84a77e9553e..d23b9441822 100644
--- a/source/blender/makesdna/intern/dna_genfile.c
+++ b/source/blender/makesdna/intern/dna_genfile.c
@@ -1398,7 +1398,7 @@ static void init_reconstruct_step_for_member(const SDNA *oldsdna,
r_step->data.cast_pointer.array_len = shared_array_length;
}
else {
- BLI_assert(!"invalid pointer size");
+ BLI_assert_msg(0, "invalid pointer size");
r_step->type = RECONSTRUCT_STEP_INIT_ZERO;
}
break;
diff --git a/source/blender/makesrna/intern/rna_access.c b/source/blender/makesrna/intern/rna_access.c
index eb347987f87..0285ef44e17 100644
--- a/source/blender/makesrna/intern/rna_access.c
+++ b/source/blender/makesrna/intern/rna_access.c
@@ -5864,12 +5864,12 @@ ID *RNA_find_real_ID_and_path(Main *bmain, ID *id, const char **r_path)
*r_path = "collection";
break;
default:
- BLI_assert(!"Missing handling of embedded id type.");
+ BLI_assert_msg(0, "Missing handling of embedded id type.");
}
}
if (id_type->owner_get == NULL) {
- BLI_assert(!"Missing handling of embedded id type.");
+ BLI_assert_msg(0, "Missing handling of embedded id type.");
return id;
}
return id_type->owner_get(bmain, id);
diff --git a/source/blender/makesrna/intern/rna_access_compare_override.c b/source/blender/makesrna/intern/rna_access_compare_override.c
index c4d35140423..3912c873fd0 100644
--- a/source/blender/makesrna/intern/rna_access_compare_override.c
+++ b/source/blender/makesrna/intern/rna_access_compare_override.c
@@ -867,7 +867,7 @@ bool RNA_struct_override_matches(Main *bmain,
else {
/* Too noisy for now, this triggers on runtime props like transform matrices etc. */
#if 0
- BLI_assert(!"We have differences between reference and "
+ BLI_assert_msg(0, "We have differences between reference and "
"overriding data on non-editable property.");
#endif
matching = false;
diff --git a/source/blender/makesrna/intern/rna_define.c b/source/blender/makesrna/intern/rna_define.c
index 1a0d4ebb7e6..fadce9e3c89 100644
--- a/source/blender/makesrna/intern/rna_define.c
+++ b/source/blender/makesrna/intern/rna_define.c
@@ -52,7 +52,7 @@ static CLG_LogRef LOG = {"rna.define"};
# define ASSERT_SOFT_HARD_LIMITS \
if (softmin < hardmin || softmax > hardmax) { \
CLOG_ERROR(&LOG, "error with soft/hard limits: %s.%s", CONTAINER_RNA_ID(cont), identifier); \
- BLI_assert(!"invalid soft/hard limits"); \
+ BLI_assert_msg(0, "invalid soft/hard limits"); \
} \
(void)0
#else
diff --git a/source/blender/makesrna/intern/rna_mask.c b/source/blender/makesrna/intern/rna_mask.c
index 896e253049b..8c7d9698a67 100644
--- a/source/blender/makesrna/intern/rna_mask.c
+++ b/source/blender/makesrna/intern/rna_mask.c
@@ -505,7 +505,7 @@ static void rna_MaskSpline_points_add(ID *id, MaskSpline *spline, int count)
if (!layer) {
/* Shall not happen actually */
- BLI_assert(!"No layer found for the spline");
+ BLI_assert_msg(0, "No layer found for the spline");
return;
}
diff --git a/source/blender/makesrna/intern/rna_nodetree.c b/source/blender/makesrna/intern/rna_nodetree.c
index cfd83a85d2e..4712f4a0a0b 100644
--- a/source/blender/makesrna/intern/rna_nodetree.c
+++ b/source/blender/makesrna/intern/rna_nodetree.c
@@ -4388,7 +4388,7 @@ static int point_density_particle_color_source_from_shader(
case SHD_POINTDENSITY_COLOR_PARTVEL:
return TEX_PD_COLOR_PARTVEL;
default:
- BLI_assert(!"Unknown color source");
+ BLI_assert_msg(0, "Unknown color source");
return TEX_PD_COLOR_CONSTANT;
}
}
@@ -4404,7 +4404,7 @@ static int point_density_vertex_color_source_from_shader(
case SHD_POINTDENSITY_COLOR_VERTNOR:
return TEX_PD_COLOR_VERTNOR;
default:
- BLI_assert(!"Unknown color source");
+ BLI_assert_msg(0, "Unknown color source");
return TEX_PD_COLOR_CONSTANT;
}
}
diff --git a/source/blender/makesrna/intern/rna_object_force.c b/source/blender/makesrna/intern/rna_object_force.c
index f8a98eb1753..98d59bf3a1a 100644
--- a/source/blender/makesrna/intern/rna_object_force.c
+++ b/source/blender/makesrna/intern/rna_object_force.c
@@ -133,8 +133,9 @@ static bool rna_Cache_get_valid_owner_ID(PointerRNA *ptr, Object **ob, Scene **s
*scene = (Scene *)ptr->owner_id;
break;
default:
- BLI_assert(!"Trying to get PTCacheID from an invalid ID type "
- "(Only scenes and objects are supported).");
+ BLI_assert_msg(0,
+ "Trying to get PTCacheID from an invalid ID type "
+ "(Only scenes and objects are supported).");
break;
}
diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c
index 7366934695e..1d00c379b06 100644
--- a/source/blender/makesrna/intern/rna_space.c
+++ b/source/blender/makesrna/intern/rna_space.c
@@ -2715,7 +2715,7 @@ static StructRNA *rna_FileBrowser_params_typef(PointerRNA *ptr)
return &RNA_FileAssetSelectParams;
}
- BLI_assert(!"Could not identify file select parameters");
+ BLI_assert_msg(0, "Could not identify file select parameters");
return NULL;
}
diff --git a/source/blender/makesrna/intern/rna_ui.c b/source/blender/makesrna/intern/rna_ui.c
index d4ae5f1ecfc..849bbca16f4 100644
--- a/source/blender/makesrna/intern/rna_ui.c
+++ b/source/blender/makesrna/intern/rna_ui.c
@@ -1014,7 +1014,7 @@ static void rna_Panel_bl_description_set(PointerRNA *ptr, const char *value)
BLI_strncpy(str, value, RNA_DYN_DESCR_MAX); /* utf8 already ensured */
}
else {
- BLI_assert(!"setting the bl_description on a non-builtin panel");
+ BLI_assert_msg(0, "setting the bl_description on a non-builtin panel");
}
}
@@ -1026,7 +1026,7 @@ static void rna_Menu_bl_description_set(PointerRNA *ptr, const char *value)
BLI_strncpy(str, value, RNA_DYN_DESCR_MAX); /* utf8 already ensured */
}
else {
- BLI_assert(!"setting the bl_description on a non-builtin menu");
+ BLI_assert_msg(0, "setting the bl_description on a non-builtin menu");
}
}
diff --git a/source/blender/makesrna/intern/rna_wm.c b/source/blender/makesrna/intern/rna_wm.c
index afbde26e59e..2a4abac04f8 100644
--- a/source/blender/makesrna/intern/rna_wm.c
+++ b/source/blender/makesrna/intern/rna_wm.c
@@ -1765,7 +1765,7 @@ static void rna_Operator_bl_idname_set(PointerRNA *ptr, const char *value)
BLI_strncpy(str, value, OP_MAX_TYPENAME); /* utf8 already ensured */
}
else {
- BLI_assert(!"setting the bl_idname on a non-builtin operator");
+ BLI_assert_msg(0, "setting the bl_idname on a non-builtin operator");
}
}
@@ -1777,7 +1777,7 @@ static void rna_Operator_bl_label_set(PointerRNA *ptr, const char *value)
BLI_strncpy(str, value, OP_MAX_TYPENAME); /* utf8 already ensured */
}
else {
- BLI_assert(!"setting the bl_label on a non-builtin operator");
+ BLI_assert_msg(0, "setting the bl_label on a non-builtin operator");
}
}
diff --git a/source/blender/makesrna/intern/rna_wm_gizmo.c b/source/blender/makesrna/intern/rna_wm_gizmo.c
index 076a77d4fb5..6a1574f3dbe 100644
--- a/source/blender/makesrna/intern/rna_wm_gizmo.c
+++ b/source/blender/makesrna/intern/rna_wm_gizmo.c
@@ -244,7 +244,7 @@ static void rna_Gizmo_bl_idname_set(PointerRNA *ptr, const char *value)
BLI_strncpy(str, value, MAX_NAME); /* utf8 already ensured */
}
else {
- BLI_assert(!"setting the bl_idname on a non-builtin operator");
+ BLI_assert_msg(0, "setting the bl_idname on a non-builtin operator");
}
}
@@ -643,7 +643,7 @@ static void rna_GizmoGroup_bl_idname_set(PointerRNA *ptr, const char *value)
BLI_strncpy(str, value, MAX_NAME); /* utf8 already ensured */
}
else {
- BLI_assert(!"setting the bl_idname on a non-builtin operator");
+ BLI_assert_msg(0, "setting the bl_idname on a non-builtin operator");
}
}
@@ -655,7 +655,7 @@ static void rna_GizmoGroup_bl_label_set(PointerRNA *ptr, const char *value)
BLI_strncpy(str, value, MAX_NAME); /* utf8 already ensured */
}
else {
- BLI_assert(!"setting the bl_label on a non-builtin operator");
+ BLI_assert_msg(0, "setting the bl_label on a non-builtin operator");
}
}
diff --git a/source/blender/nodes/geometry/nodes/node_geo_convex_hull.cc b/source/blender/nodes/geometry/nodes/node_geo_convex_hull.cc
index b1b17a321b8..4286db52115 100644
--- a/source/blender/nodes/geometry/nodes/node_geo_convex_hull.cc
+++ b/source/blender/nodes/geometry/nodes/node_geo_convex_hull.cc
@@ -82,7 +82,7 @@ static Mesh *hull_from_bullet(const Mesh *mesh, Span<float3> coords)
copy_v3_v3(result->mvert[i].co, co);
}
else {
- BLI_assert(!"Unexpected new vertex in hull output");
+ BLI_assert_msg(0, "Unexpected new vertex in hull output");
}
}
diff --git a/source/blender/python/intern/bpy_app_handlers.c b/source/blender/python/intern/bpy_app_handlers.c
index 7c5c1122aea..8dc5a6c629c 100644
--- a/source/blender/python/intern/bpy_app_handlers.c
+++ b/source/blender/python/intern/bpy_app_handlers.c
@@ -225,7 +225,7 @@ PyObject *BPY_app_handlers_struct(void)
#endif
if (PyType_Ready(&BPyPersistent_Type) < 0) {
- BLI_assert(!"error initializing 'bpy.app.handlers.persistent'");
+ BLI_assert_msg(0, "error initializing 'bpy.app.handlers.persistent'");
}
PyStructSequence_InitType(&BlenderAppCbType, &app_cb_info_desc);
diff --git a/source/blender/python/intern/bpy_rna.c b/source/blender/python/intern/bpy_rna.c
index a8ab54ac3bb..e6f3e509469 100644
--- a/source/blender/python/intern/bpy_rna.c
+++ b/source/blender/python/intern/bpy_rna.c
@@ -2728,7 +2728,7 @@ static PyObject *pyrna_prop_array_subscript_slice(BPy_PropertyArrayRNA *self,
break;
}
default:
- BLI_assert(!"Invalid array type");
+ BLI_assert_msg(0, "Invalid array type");
PyErr_SetString(PyExc_TypeError, "not an array type");
Py_DECREF(tuple);
@@ -4375,7 +4375,7 @@ static PyObject *pyrna_struct_getattro(BPy_StructRNA *self, PyObject *pyname)
}
default:
/* Should never happen. */
- BLI_assert(!"Invalid context type");
+ BLI_assert_msg(0, "Invalid context type");
PyErr_Format(PyExc_AttributeError,
"bpy_struct: Context type invalid %d, can't get \"%.200s\" from context",
@@ -5389,7 +5389,7 @@ static PyObject *foreach_getset(BPy_PropertyRNA *self, PyObject *args, int set)
break;
case PROP_RAW_UNSET:
/* Should never happen. */
- BLI_assert(!"Invalid array type - set");
+ BLI_assert_msg(0, "Invalid array type - set");
break;
}
@@ -5453,7 +5453,7 @@ static PyObject *foreach_getset(BPy_PropertyRNA *self, PyObject *args, int set)
break;
default: /* PROP_RAW_UNSET */
/* Should never happen. */
- BLI_assert(!"Invalid array type - get");
+ BLI_assert_msg(0, "Invalid array type - get");
item = Py_None;
Py_INCREF(item);
break;
diff --git a/source/blender/python/mathutils/mathutils_Color.c b/source/blender/python/mathutils/mathutils_Color.c
index 819874e4355..7546f2ef730 100644
--- a/source/blender/python/mathutils/mathutils_Color.c
+++ b/source/blender/python/mathutils/mathutils_Color.c
@@ -570,7 +570,7 @@ static PyObject *Color_mul(PyObject *v1, PyObject *v2)
}
}
else {
- BLI_assert(!"internal error");
+ BLI_assert_msg(0, "internal error");
}
PyErr_Format(PyExc_TypeError,
diff --git a/source/blender/sequencer/intern/image_cache.c b/source/blender/sequencer/intern/image_cache.c
index a6e4b6ea7ed..604c9900355 100644
--- a/source/blender/sequencer/intern/image_cache.c
+++ b/source/blender/sequencer/intern/image_cache.c
@@ -521,7 +521,7 @@ static bool seq_disk_cache_read_header(FILE *file, DiskCacheHeader *header)
BLI_fseek(file, 0LL, SEEK_SET);
const size_t num_items_read = fread(header, sizeof(*header), 1, file);
if (num_items_read < 1) {
- BLI_assert(!"unable to read disk cache header");
+ BLI_assert_msg(0, "unable to read disk cache header");
perror("unable to read disk cache header");
return false;
}
diff --git a/source/blender/sequencer/intern/render.c b/source/blender/sequencer/intern/render.c
index 28ff78cecf6..aba84743621 100644
--- a/source/blender/sequencer/intern/render.c
+++ b/source/blender/sequencer/intern/render.c
@@ -370,7 +370,7 @@ int seq_get_shown_sequences(ListBase *seqbase,
const int strip_count = BLI_gset_len(collection->set);
if (strip_count > MAXSEQ) {
- BLI_assert(!"Too many strips, this shouldn't happen");
+ BLI_assert_msg(0, "Too many strips, this shouldn't happen");
return 0;
}
diff --git a/source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c b/source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c
index 6e4e66d0daf..6a328679c2e 100644
--- a/source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c
+++ b/source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c
@@ -264,7 +264,7 @@ bool WM_gizmomap_minmax(const wmGizmoMap *gzmap,
}
bool ok = false;
- BLI_assert(!"TODO");
+ BLI_assert_msg(0, "TODO");
return ok;
}
diff --git a/source/blender/windowmanager/intern/wm_cursors.c b/source/blender/windowmanager/intern/wm_cursors.c
index 93b8495b309..50d3a856cbe 100644
--- a/source/blender/windowmanager/intern/wm_cursors.c
+++ b/source/blender/windowmanager/intern/wm_cursors.c
@@ -163,7 +163,7 @@ void WM_cursor_set(wmWindow *win, int curs)
win->cursor = curs;
if (curs < 0 || curs >= WM_CURSOR_NUM) {
- BLI_assert(!"Invalid cursor number");
+ BLI_assert_msg(0, "Invalid cursor number");
return;
}
diff --git a/source/blender/windowmanager/intern/wm_dragdrop.c b/source/blender/windowmanager/intern/wm_dragdrop.c
index 435b3538e5f..da40040ce56 100644
--- a/source/blender/windowmanager/intern/wm_dragdrop.c
+++ b/source/blender/windowmanager/intern/wm_dragdrop.c
@@ -321,7 +321,7 @@ void WM_drag_add_local_ID(wmDrag *drag, ID *id, ID *from_parent)
return;
}
if (GS(drag_id->id->name) != GS(id->name)) {
- BLI_assert(!"All dragged IDs must have the same type");
+ BLI_assert_msg(0, "All dragged IDs must have the same type");
return;
}
}
diff --git a/source/blender/windowmanager/intern/wm_files.c b/source/blender/windowmanager/intern/wm_files.c
index c85727175b2..3633d3c07d3 100644
--- a/source/blender/windowmanager/intern/wm_files.c
+++ b/source/blender/windowmanager/intern/wm_files.c
@@ -929,7 +929,7 @@ bool WM_file_read(bContext *C, const char *filepath, ReportList *reports)
}
else {
BKE_reportf(reports, RPT_ERROR, "Unknown error loading '%s'", filepath);
- BLI_assert(!"invalid 'retval'");
+ BLI_assert_msg(0, "invalid 'retval'");
}
if (success == false) {
diff --git a/source/blender/windowmanager/intern/wm_keymap.c b/source/blender/windowmanager/intern/wm_keymap.c
index e9039f3b03f..25bcf1967ea 100644
--- a/source/blender/windowmanager/intern/wm_keymap.c
+++ b/source/blender/windowmanager/intern/wm_keymap.c
@@ -971,7 +971,7 @@ static const wmKeyMapItem *wm_modalkeymap_find_propvalue_iter(const wmKeyMap *km
}
}
else {
- BLI_assert(!"called with non modal keymap");
+ BLI_assert_msg(0, "called with non modal keymap");
}
return NULL;