Re: VARATT_EXTERNAL_GET_POINTER is not quite there yet

Поиск
Список
Период
Сортировка
Искать
От
Gregory Stark
Тема
Re: VARATT_EXTERNAL_GET_POINTER is not quite there yet
Дата
Msg-id
87ir0ivflh.fsf@oxford.xeocode.com
Ответ на
Список
Дерево обсуждения
VARATT_EXTERNAL_GET_POINTER is not quite there yet Tom Lane <tgl@sss.pgh.pa.us>
Re: VARATT_EXTERNAL_GET_POINTER is not quite there yet Gregory Stark <stark@enterprisedb.com>
Re: VARATT_EXTERNAL_GET_POINTER is not quite there yet Tom Lane <tgl@sss.pgh.pa.us>
Re: VARATT_EXTERNAL_GET_POINTER is not quite there yet Gregory Stark <stark@enterprisedb.com>
Re: VARATT_EXTERNAL_GET_POINTER is not quite there yet Tom Lane <tgl@sss.pgh.pa.us>
Re: VARATT_EXTERNAL_GET_POINTER is not quite there yet Bruce Momjian <bruce@momjian.us>
"Tom Lane"  writes:

> After much experimentation I was able to get it to work by invoking
> memcpy through a function pointer, which seems to be sufficient to
> disable this particular compiler's built-in intelligence about memcpy.
> I can't say that I find this a nice clean solution; but does anyone have
> a better one?

I'm thinking instead of having struct varlena (which you're not allowed to
safely use any members of anyways) we should just have a typedef to void*.

That would make things like DATUM_GET_TEXT_PP slightly more sane as well.
text* would just be a typedef to void* which could be passed to VARDATA_ANY
and VARDATA_ANY_EXHDR but not manipulated directly.

--  Gregory Stark EnterpriseDB          http://www.enterprisedb.com Get trained by Bruce Momjian - ask me about EnterpriseDB's PostgreSQL training!

В списке pgsql-hackers по дате отправления
От: Gevik Babakhani
Дата:
Сообщение: Re: Which MemoryContext?
От: Magnus Hagander
Дата:
Сообщение: Re: Permanent settings
FAQ