[Tarantool-patches] [PATCH v4 2/6] sql: refactor create_table_def and parse
Roman Khabibov
roman.habibov at tarantool.org
Thu Oct 8 13:32:23 MSK 2020
Hi!
> On Oct 8, 2020, at 01:35, Vladislav Shpilevoy <v.shpilevoy at tarantool.org> wrote:
>
> Hi! Thanks for the answer!
>
>>>> diff --git a/src/box/sql/parse_def.h b/src/box/sql/parse_def.h
>>>> index cb0ecd2fc..21829b6f0 100644
>>>> --- a/src/box/sql/parse_def.h
>>>> +++ b/src/box/sql/parse_def.h
>>>> @@ -500,12 +505,12 @@ create_view_def_init(struct create_view_def *view_def, struct Token *name,
>>>> }
>>>>
>>>> static inline void
>>>> -create_table_def_destroy(struct create_table_def *table_def)
>>>> +create_fkeys_def_destroy(struct create_fkeys_def *fkeys_def)
>>>
>>> Where is create_checks_def destroyed?
>> There's nothing to destroy in create_checks_def. Or is it worth
>> creating it to keep the formality?
>
> It has a list of ck_constraint_parse objects, which have ck_constraint_def
> objects. What is the memory they are allocated on?
>
On region.
https://github.com/tarantool/tarantool/blob/0dc72812fb78a192945612f0e954026a0ffe4053/src/box/sql/build.c#L614
https://github.com/tarantool/tarantool/blob/0dc72812fb78a192945612f0e954026a0ffe4053/src/box/sql/build.c#L1979
More information about the Tarantool-patches
mailing list