Tarantool development patches archive
 help / color / mirror / Atom feed
From: Kirill Shcherbatov <kshcherbatov@tarantool.org>
To: tarantool-patches@freelists.org,
	Vladimir Davydov <vdavydov.dev@gmail.com>
Subject: Re: [tarantool-patches] Re: [PATCH v5 1/4] box: introduce tuple_format_iterator class
Date: Mon, 6 May 2019 17:32:37 +0300	[thread overview]
Message-ID: <e74b5dbf-cc9f-6d9b-97fc-10a0042ff01b@tarantool.org> (raw)
In-Reply-To: <20190506135555.wgtewxgznfta3uss@esperanza>

>> +	uint32_t total_sz = frames_sz + 2 * it->required_fields_sz;
> 
> 2 * ?
> 
> Shouldn't this be a part of the next patch?

Yep. Moved to the last patch.

>> +	mp_stack_create(&it->stack, format->fields_depth, frames);
>> +	*defined_field_count = MIN(*defined_field_count, validate ?
> 
> Shouldn't we use KEY_PARTS_ONLY here rather than VALIDATE?

Yes, this works.

>> +/**
>> + * Scan required_fields bitmap and raise error when it is
>> + * non-empty.
>> + * @sa format:required_fields and field:multikey_required_fields
>> + * definition.
> 
> There's no such thing as multikey_required_fields yet.

Moved to the last patch.

>> +	case MP_MAP:
>> +		if (mp_typeof(*it->pos) != MP_STR) {
>> +			entry->data = it->pos;
>> +			entry->field = NULL;
>> +			mp_next(&it->pos);
>> +			mp_next(&it->pos);
> 
> What about entry->data_end?

Both of them are redundant, entry->data must be only != NULL.
But I've updated data_end correspondingly:

case MP_MAP:
		if (mp_typeof(*it->pos) != MP_STR) {
			entry->field = NULL;
			mp_next(&it->pos);
			entry->data = it->pos;
			mp_next(&it->pos);
			entry->data_end = it->pos;
			return 0;
		}

==============================================

Updated patch on branch.

  reply	other threads:[~2019-05-06 14:32 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-06 11:57 [PATCH v5 0/4] box: introduce multikey indexes in memtx Kirill Shcherbatov
2019-05-06 11:57 ` [PATCH v5 1/4] box: introduce tuple_format_iterator class Kirill Shcherbatov
2019-05-06 13:55   ` Vladimir Davydov
2019-05-06 14:32     ` Kirill Shcherbatov [this message]
2019-05-06 11:57 ` [PATCH v5 2/4] box: introduce field_map_builder class Kirill Shcherbatov
2019-05-06 14:22   ` Vladimir Davydov
2019-05-06 11:57 ` [PATCH v5 3/4] salad: introduce bps_tree_delete_identical routine Kirill Shcherbatov
2019-05-06 14:34   ` Vladimir Davydov
2019-05-06 14:55     ` [tarantool-patches] " Kirill Shcherbatov
2019-05-06 11:57 ` [PATCH v5 4/4] box: introduce multikey indexes in memtx Kirill Shcherbatov
2019-05-06 15:46   ` Vladimir Davydov
2019-05-06 16:35     ` [tarantool-patches] " Kirill Shcherbatov
2019-05-07  8:11       ` Vladimir Davydov
2019-05-07  8:28         ` Kirill Shcherbatov
2019-05-07 11:30           ` Vladimir Davydov
2019-05-07 13:13     ` Vladimir Davydov
2019-05-06 15:52 ` [PATCH v5 0/4] " Vladimir Davydov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e74b5dbf-cc9f-6d9b-97fc-10a0042ff01b@tarantool.org \
    --to=kshcherbatov@tarantool.org \
    --cc=tarantool-patches@freelists.org \
    --cc=vdavydov.dev@gmail.com \
    --subject='Re: [tarantool-patches] Re: [PATCH v5 1/4] box: introduce tuple_format_iterator class' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox