Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:4466 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 68180 invoked by uid 1010); 14 Sep 2003 01:11:35 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 68124 invoked by uid 1007); 14 Sep 2003 01:11:35 -0000 Message-ID: <20030914011135.68123.qmail@pb1.pair.com> To: internals@lists.php.net Date: Sun, 14 Sep 2003 03:12:14 +0200 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5b) Gecko/20030901 Thunderbird/0.2 X-Accept-Language: en-us, en MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Posted-By: 80.126.21.70 Subject: attribute format not workng for GCC-3.0 From: abies@php.net (Ard Biesheuvel) Could someone commit the following patch to zend.h in HEAD and PHP_4_3 ? The __attribute__ ((format)) doesn't work for function pointers on gcc-3.0, (see bug #25528) Wouldn't it be better to #define all these format attributes void when ZEND_DEBUG is disabled, as they're really only helpful for debugging, but useless for production code ? Ard Index: zend.h =================================================================== RCS file: /repository/ZendEngine2/zend.h,v retrieving revision 1.224 diff -u -r1.224 zend.h --- zend.h 31 Aug 2003 09:35:54 -0000 1.224 +++ zend.h 14 Sep 2003 01:03:52 -0000 @@ -164,7 +164,7 @@ # define ZEND_ATTRIBUTE_FORMAT(type, idx, first) #endif -#if ZEND_GCC_VERSION >= 3000 +#if ZEND_GCC_VERSION >= 3002 # define ZEND_ATTRIBUTE_PTR_FORMAT(type, idx, first) __attribute__ ((format(type, idx, first))) #else # define ZEND_ATTRIBUTE_PTR_FORMAT(type, idx, first)