| 555 | } |
| 556 | |
| 557 | static void decode_struct_profile(const char *props_json, float *out) { |
| 558 | memset(out, 0, sizeof(float) * CBM_AST_PROFILE_DIMS); |
| 559 | if (!props_json) { |
| 560 | return; |
| 561 | } |
| 562 | char sp_buf[CBM_AST_PROFILE_BUF]; |
| 563 | if (json_str_value(props_json, "sp", sp_buf, sizeof(sp_buf))) { |
| 564 | cbm_ast_profile_t profile; |
| 565 | if (cbm_ast_profile_from_str(sp_buf, &profile)) { |
| 566 | cbm_ast_profile_to_vector(&profile, out); |
| 567 | } |
| 568 | } |
| 569 | } |
| 570 | |
| 571 | static void decode_minhash(const char *props_json, cbm_sem_func_t *func) { |
| 572 | func->has_minhash = false; |
no test coverage detected