Skip to content

Commit

Permalink
Add support for arithmetic expressions in deserializer
Browse files Browse the repository at this point in the history
  • Loading branch information
SanderMertens committed Sep 17, 2022
1 parent cf5c91d commit a824587
Show file tree
Hide file tree
Showing 11 changed files with 3,289 additions and 180 deletions.
787 changes: 700 additions & 87 deletions flecs.c

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions flecs.h
Original file line number Diff line number Diff line change
Expand Up @@ -12175,10 +12175,13 @@ typedef struct ecs_parse_expr_desc_t {
* This operation parses a flecs expression into the provided pointer. The
* memory pointed to must be large enough to contain a value of the used type.
*
* If no type and pointer are provided for the value argument, the operation
* will discover the type from the expression and allocate storage for the
* value. The allocated value must be freed with ecs_value_free.
*
* @param world The world.
* @param ptr The pointer to the expression to parse.
* @param type The type of the expression to parse.
* @param data_out Pointer to the memory to write to.
* @param value The value containing type & pointer to write to.
* @param desc Configuration parameters for deserializer.
* @return Pointer to the character after the last one read, or NULL if failed.
*/
Expand Down
7 changes: 5 additions & 2 deletions include/flecs/addons/expr.h
Original file line number Diff line number Diff line change
Expand Up @@ -181,10 +181,13 @@ typedef struct ecs_parse_expr_desc_t {
* This operation parses a flecs expression into the provided pointer. The
* memory pointed to must be large enough to contain a value of the used type.
*
* If no type and pointer are provided for the value argument, the operation
* will discover the type from the expression and allocate storage for the
* value. The allocated value must be freed with ecs_value_free.
*
* @param world The world.
* @param ptr The pointer to the expression to parse.
* @param type The type of the expression to parse.
* @param data_out Pointer to the memory to write to.
* @param value The value containing type & pointer to write to.
* @param desc Configuration parameters for deserializer.
* @return Pointer to the character after the last one read, or NULL if failed.
*/
Expand Down
Loading

0 comments on commit a824587

Please sign in to comment.