[Tarantool-patches] [PATCH v3 14/16] module api: expose box_key_def_extract_key()

Vladislav Shpilevoy v.shpilevoy at tarantool.org
Thu Oct 15 02:41:51 MSK 2020


Thanks for the patch!

> diff --git a/src/box/key_def.c b/src/box/key_def.c
> index 7226f2482..da1c23135 100644
> --- a/src/box/key_def.c
> +++ b/src/box/key_def.c
> @@ -620,6 +620,13 @@ box_key_def_merge(const box_key_def_t *first, const box_key_def_t *second)
>  	return key_def_merge(first, second);
>  }
>  
> +char *
> +box_key_def_extract_key(box_key_def_t *key_def, box_tuple_t *tuple,
> +			int multikey_idx, uint32_t *key_size_ptr)

I would try to make the tuple const here. Key_def can't be const (because
multikey updates some values in it even in simple getters), but the tuple
can. Although it requires const addition to several internal functions.


More information about the Tarantool-patches mailing list