Re: pgsql: Allow opclasses to provide tri-valued GIN consistent functions.

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: pgsql: Allow opclasses to provide tri-valued GIN consistent functions.
Дата
Msg-id 532EEB64.40408@dunslane.net
обсуждение исходный текст
Ответ на Re: pgsql: Allow opclasses to provide tri-valued GIN consistent functions.  (Heikki Linnakangas <hlinnakangas@vmware.com>)
Список pgsql-committers
On 03/23/2014 09:22 AM, Heikki Linnakangas wrote:
>
> Here's the code from gin.h (after fixing the issues Andres and Tom
> pointed out):
>
>> enum GinLogicValueEnum
>> {
>>         GIN_FALSE = 0,                  /* item is not present / does
>> not match */
>>         GIN_TRUE = 1,                   /* item is present / matches */
>>         GIN_MAYBE = 2                   /* don't know if item is
>> present / don't know if
>>                                                          * matches */
>> };
>>
>> typedef char GinLogicValue;
>
> The reason for the typedef is precisely that an enum is not guaranteed
> to be one byte. Tom suggested getting rid of the typedef, but it's
> needed to make sure it's stored as one byte.
>
> I'll go add a comment to it, explaining why it's needed.
>
>

Ak, OK, I probably misread your previous email.

cheers

andrew



В списке pgsql-committers по дате отправления:

Предыдущее
От: Heikki Linnakangas
Дата:
Сообщение: Re: pgsql: Allow opclasses to provide tri-valued GIN consistent functions.
Следующее
От: Greg Stark
Дата:
Сообщение: Re: pgsql: Allow opclasses to provide tri-valued GIN consistent functions.