Re: BUG #14167: ecpg parser cann't ignore code in #ifdef ?

Поиск
Список
Период
Сортировка
От 德哥
Тема Re: BUG #14167: ecpg parser cann't ignore code in #ifdef ?
Дата
Msg-id 36b4b4cd.1914.1550ea3c586.Coremail.digoal@126.com
обсуждение исходный текст
Ответ на Re: BUG #14167: ecpg parser cann't ignore code in #ifdef ?  (Michael Meskes <meskes@postgresql.org>)
Ответы Re: BUG #14167: ecpg parser cann't ignore code in #ifdef ?  (Michael Paquier <michael.paquier@gmail.com>)
Список pgsql-bugs

HI,
Thanks very much, 
Because I see EDB's document ECPGplus can parser #ifdef.  
so why postgresql community not do that? 
I think many PG user need it to adpate some enviroment (like Oracle , pg, db2, ...) in .pgc code. 

best regards , 
digoal 


--
公益是一辈子的事,I'm Digoal,Just Do It.


At 2016-06-01 21:43:00, "Michael Meskes" <meskes@postgresql.org> wrote: >>   this is my pgc code.   >> ... >> #ifdef ABC >>     err *abc; >> #endif >> ... >> this is ERROR >> ecpg -t -c -I/home/digoal/pgsql9.6/include -o t.c t.pgc >> t.pgc:15: ERROR: unrecognized data type name "err" >> >> And use #ifndef and -DABC also error.  >> ECPG parser cann't skip code in #ifdef or #ifndef ? > >'#ifdef' is a C precompiler command and thus is only parsed by cpp et >al. If you want ecpg to parse it you have to use 'exec sql ifdef' >instead. > >Michael >-- >Michael Meskes >Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org) >Meskes at (Debian|Postgresql) dot Org >Jabber: michael at xmpp dot meskes dot org >VfL Borussia! Força Barça! SF 49ers! Use Debian GNU/Linux, PostgreSQL

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

Предыдущее
От: Ganesh Kannan
Дата:
Сообщение: Re: BUG #14168: ALTER TABLE SET LOGGED failing
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: BUG #14167: ecpg parser cann't ignore code in #ifdef ?