@@ -409,108 +409,176 @@ FLECS_ALWAYS_INLINE ecs_table_t *flecs_table_traverse_add(
409409
410410#ifdef FLECS_MUT_ALIAS_LOCKS
411411
412- /** Begin read lock on sparse component record.
412+ /** Begin read lock on sparse component record.
413413 * a sparse id is a component marked either as sparse or non-fragmenting
414- */
414+ *
415+ * @param cr The component record.
416+ * @return true if the mut alias was violated, false otherwise.
417+ */
415418FLECS_API
416419FLECS_ALWAYS_INLINE bool flecs_sparse_id_record_lock_read_begin (
417420 ecs_component_record_t * cr );
418421
419422/** End read lock on sparse component record.
420423 * a sparse id is a component marked either as sparse or non-fragmenting
424+ *
425+ * @param cr The component record.
426+ * @return true if the mut alias was violated, false otherwise.
421427*/
422428FLECS_API
423429FLECS_ALWAYS_INLINE bool flecs_sparse_id_record_lock_read_end (
424430 ecs_component_record_t * cr );
425431
426432/** Begin write lock on sparse component record.
427433 * a sparse id is a component marked either as sparse or non-fragmenting
434+ *
435+ * @param cr The component record.
436+ * @return true if the mut alias was violated, false otherwise.
428437*/
429438FLECS_API
430439FLECS_ALWAYS_INLINE bool flecs_sparse_id_record_lock_write_begin (
431440 ecs_component_record_t * cr );
432441
433442/** End write lock on sparse component record.
434443 * a sparse id is a component marked either as sparse or non-fragmenting
444+ *
445+ * @param cr The component record.
446+ * @return true if the mut alias was violated, false otherwise.
435447*/
436448FLECS_API
437449FLECS_ALWAYS_INLINE bool flecs_sparse_id_record_lock_write_end (
438450 ecs_component_record_t * cr );
439451
440- /** Begin read lock on table column. */
452+ /** Begin read lock on table column.
453+ *
454+ * @param table The table.
455+ * @param column_index The column index in the table.
456+ * @return true if the mut alias was violated, false otherwise.
457+ */
441458FLECS_API
442459FLECS_ALWAYS_INLINE bool flecs_table_column_lock_read_begin (
443460 ecs_table_t * table ,
444461 const int16_t column_index );
445462
446- /** End read lock on table column. */
463+ /** End read lock on table column.
464+ *
465+ * @param table The table.
466+ * @param column_index The column index in the table.
467+ * @return true if the mut alias was violated, false otherwise.
468+ */
447469FLECS_API
448470FLECS_ALWAYS_INLINE bool flecs_table_column_lock_read_end (
449471 ecs_table_t * table ,
450472 const int16_t column_index );
451473
452- /** Begin write lock on table column. */
474+ /** Begin write lock on table column.
475+ *
476+ * @param table The table.
477+ * @param column_index The column index in the table.
478+ * @return true if the mut alias was violated, false otherwise.
479+ */
453480FLECS_API
454481FLECS_ALWAYS_INLINE bool flecs_table_column_lock_write_begin (
455482 ecs_table_t * table ,
456483 const int16_t column_index );
457484
458- /** End write lock on table column. */
485+ /** End write lock on table column.
486+ *
487+ * @param table The table.
488+ * @param column_index The column index in the table.
489+ * @return true if the mut alias was violated, false otherwise.
490+ */
459491FLECS_API
460492FLECS_ALWAYS_INLINE bool flecs_table_column_lock_write_end (
461493 ecs_table_t * table ,
462494 const int16_t column_index );
463495
464- /* Begin read lock on sparse component record in multithreaded context.
496+ /** Begin read lock on sparse component record in multithreaded context.
465497 * a sparse id is a component marked either as sparse or non-fragmenting
498+ *
499+ * @param cr The component record.
500+ * @return true if the mut alias was violated, false otherwise.
466501*/
467502FLECS_API
468503FLECS_ALWAYS_INLINE bool flecs_sparse_id_record_lock_read_begin_multithreaded (
469504 ecs_component_record_t * cr );
470505
471- /* End read lock on sparse component record in multithreaded context.
506+ /** End read lock on sparse component record in multithreaded context.
472507 * a sparse id is a component marked either as sparse or non-fragmenting
508+ *
509+ * @param cr The component record.
510+ * @return true if the mut alias was violated, false otherwise.
473511*/
474512FLECS_API
475513FLECS_ALWAYS_INLINE bool flecs_sparse_id_record_lock_read_end_multithreaded (
476514 ecs_component_record_t * cr );
477515
478- /* Begin write lock on sparse component record in multithreaded context.
516+ /** Begin write lock on sparse component record in multithreaded context.
479517 * a sparse id is a component marked either as sparse or non-fragmenting
518+ *
519+ * @param cr The component record.
520+ * @return true if the mut alias was violated, false otherwise.
480521*/
481522FLECS_API
482523FLECS_ALWAYS_INLINE bool flecs_sparse_id_record_lock_write_begin_multithreaded (
483524 ecs_component_record_t * cr );
484525
485- /* End write lock on sparse component record in multithreaded context.
526+ /** End write lock on sparse component record in multithreaded context.
486527 * a sparse id is a component marked either as sparse or non-fragmenting
528+ *
529+ * @param cr The component record.
530+ * @return true if the mut alias was violated, false otherwise.
487531*/
488532FLECS_API
489533FLECS_ALWAYS_INLINE bool flecs_sparse_id_record_lock_write_end_multithreaded (
490534 ecs_component_record_t * cr );
491535
492- /* Begin read lock on table column in multithreaded context. */
536+ /** Begin read lock on table column in multithreaded context.
537+ *
538+ * @param table The table.
539+ * @param column_index The column index in the table.
540+ * @param stage_id The stage id of the calling thread.
541+ * @return true if the mut alias was violated, false otherwise.
542+ */
493543FLECS_API
494544FLECS_ALWAYS_INLINE bool flecs_table_column_lock_read_begin_multithreaded (
495545 ecs_table_t * table ,
496546 const int16_t column_index ,
497547 const int32_t stage_id );
498548
499- /* End read lock on table column in multithreaded context. */
549+ /** End read lock on table column in multithreaded context.
550+ *
551+ * @param table The table.
552+ * @param column_index The column index in the table.
553+ * @param stage_id The stage id of the calling thread.
554+ * @return true if the mut alias was violated, false otherwise.
555+ */
500556FLECS_API
501557FLECS_ALWAYS_INLINE bool flecs_table_column_lock_read_end_multithreaded (
502558 ecs_table_t * table ,
503559 const int16_t column_index ,
504560 const int32_t stage_id );
505561
506- /* Begin write lock on table column in multithreaded context. */
562+ /** Begin write lock on table column in multithreaded context.
563+ *
564+ * @param table The table.
565+ * @param column_index The column index in the table.
566+ * @param stage_id The stage id of the calling thread.
567+ * @return true if the mut alias was violated, false otherwise.
568+ */
507569FLECS_API
508570FLECS_ALWAYS_INLINE bool flecs_table_column_lock_write_begin_multithreaded (
509571 ecs_table_t * table ,
510572 const int16_t column_index ,
511573 const int32_t stage_id );
512574
513- /* End write lock on table column in multithreaded context. */
575+ /** End write lock on table column in multithreaded context.
576+ *
577+ * @param table The table.
578+ * @param column_index The column index in the table.
579+ * @param stage_id The stage id of the calling thread.
580+ * @return true if the mut alias was violated, false otherwise.
581+ */
514582FLECS_API
515583FLECS_ALWAYS_INLINE bool flecs_table_column_lock_write_end_multithreaded (
516584 ecs_table_t * table ,
0 commit comments