#include present twice in define.pgc

Поиск
Список
Период
Сортировка
От Ashutosh Sharma
Тема #include present twice in define.pgc
Дата
Msg-id CAE9k0PkORqHHGKY54-sFyDpP90yAf+05Auc4fs9EAn4J+uBeUQ@mail.gmail.com
обсуждение исходный текст
Ответы Re: #include present twice in define.pgc  (Peter Eisentraut <peter.eisentraut@enterprisedb.com>)
Список pgsql-interfaces
Hi All,

I could see that the #include <stdlib.h> statement is present twice in the define.pgc test file. See below:

[ashu@localhost postgresql]$ head src/interfaces/ecpg/test/preproc/define.pgc
#include <stdlib.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>

exec sql include ../regression;

...
...

Should we consider removing one of them?

I know that there won't be multiple inclusion of the same header file because of #ifndef and #define pre-processor directives which defines _STDLIB_H macro that allows the file to included just once, but I still feel that it is better to avoid having such things. It doesn't do any harm but is certainly not required. Thoughts?

--
With Regards,
Ashutosh Sharma
EnterpriseDB:http://www.enterprisedb.com

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

Предыдущее
От: Ashutosh Sharma
Дата:
Сообщение: ecpg: the comments inside the declare section are not outputted correctly.
Следующее
От: "Blum, Kimber"
Дата:
Сообщение: Issue with mysql_fdw