Re: elog with automatic file, line, and function

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: elog with automatic file, line, and function
Дата
Msg-id 8353.985048716@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: elog with automatic file, line, and function  (Ian Lance Taylor <ian@airs.com>)
Ответы Re: elog with automatic file, line, and function  (Larry Rosenman <ler@lerctr.org>)
Список pgsql-hackers
Ian Lance Taylor <ian@airs.com> writes:
> Tom Lane <tgl@sss.pgh.pa.us> writes:
>> BTW, how does that work exactly?  I assume it can't be a macro ...

> It's a macro just like __FILE__ and __LINE__ are macros.

> gcc has supported __FUNCTION__ and __PRETTY_FUNCTION__ for a long time
> (the latter is the demangled version of the function name when using
> C++).

Now that I know the name, I can find it in the gcc docs, which clearly
explain that these names are not macros ;-).  The preprocessor would
have a tough time making such a substitution.

However, if the C99 spec has such a concept, they didn't use that name
for it ...
        regards, tom lane


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: More on elog and error codes
Следующее
От: "Mikheev, Vadim"
Дата:
Сообщение: RE: Stuck spins in current