X-Original-To: pgsql-hackers-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id E42A352900 for ; Wed, 3 Aug 2005 11:31:36 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 68891-08 for ; Wed, 3 Aug 2005 14:31:27 +0000 (GMT) Received: from tigger.fuhr.org (tigger.fuhr.org [63.214.45.158]) by svr1.postgresql.org (Postfix) with ESMTP id CDF90529F2 for ; Wed, 3 Aug 2005 11:31:23 -0300 (ADT) Received: from winnie.fuhr.org (winnie.fuhr.org [10.1.0.1]) by tigger.fuhr.org (8.13.3/8.13.3) with ESMTP id j73EVPwY036719 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 3 Aug 2005 08:31:27 -0600 (MDT) (envelope-from mfuhr@winnie.fuhr.org) Received: from winnie.fuhr.org (localhost [127.0.0.1]) by winnie.fuhr.org (8.13.3/8.13.3) with ESMTP id j73EVPYZ028132 for ; Wed, 3 Aug 2005 08:31:25 -0600 (MDT) (envelope-from mfuhr@winnie.fuhr.org) Received: (from mfuhr@localhost) by winnie.fuhr.org (8.13.3/8.13.3/Submit) id j73EVPMb028131 for pgsql-hackers@postgresql.org; Wed, 3 Aug 2005 08:31:25 -0600 (MDT) (envelope-from mfuhr) Date: Wed, 3 Aug 2005 08:31:25 -0600 From: Michael Fuhr To: pgsql-hackers@postgresql.org Subject: ECPG and escape strings Message-ID: <20050803143124.GA28095@winnie.fuhr.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.005 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200508/64 X-Sequence-Number: 71259 ECPG seems to be a little overzealous with the new escape string syntax: % cat foo.pgc int main(void) { putchar('\n'); return 0; } % ecpg foo.pgc % gcc -I`pg_config --includedir` -c foo.c foo.pgc: In function `main': foo.pgc:4: `E' undeclared (first use in this function) foo.pgc:4: (Each undeclared identifier is reported only once foo.pgc:4: for each function it appears in.) foo.pgc:4: syntax error before character constant % cat foo.c /* Processed by ecpg (4.1.1) */ /* These include files are added by the preprocessor */ #include #include #include #include /* End of automatic include section */ #line 1 "foo.pgc" int main(void) { putchar(E'\n'); return 0; } -- Michael Fuhr http://www.fuhr.org/~mfuhr/