#include <include/flecs.h> FLECS_API int ecs_term_finalize(const ecs_world_t *world, ecs_term_t *term)
Finalize term. Ensure that all fields of a term are consistent and filled out. This operation should be invoked before using and after assigning members to, or parsing a term. When a term contains unresolved identifiers, this operation will resolve and assign the identifiers. If the term contains any identifiers that cannot be resolved, the operation will fail.
An application generally does not need to invoke this operation as the APIs that use terms (such as filters, queries and triggers) will finalize terms when they are created.
The name and expr parameters are optional, and only used for giving more descriptive error messages.
world- The world.
term- The term to finalize.
- Zero if success, nonzero if an error occurred.