Your message dated Fri, 21 Oct 2005 01:28:44 -0500
with message-id <[EMAIL PROTECTED]>
and subject line Bug#333231: flex generates a C file with improper macro defn; 
broke Bison 2.1
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--------------------------------------
Received: (at submit) by bugs.debian.org; 11 Oct 2005 00:10:20 +0000
>From [EMAIL PROTECTED] Mon Oct 10 17:10:20 2005
Return-path: <[EMAIL PROTECTED]>
Received: from kiwi.cs.ucla.edu [131.179.128.19] 
        by spohr.debian.org with esmtp (Exim 3.36 1 (Debian))
        id 1EP7im-0005pU-00; Mon, 10 Oct 2005 17:10:20 -0700
Received: from penguin.cs.ucla.edu (Penguin.CS.UCLA.EDU [131.179.64.200])
        by kiwi.cs.ucla.edu (8.11.7p1+Sun/8.11.7/UCLACS-5.2) with ESMTP id 
j9B09h425596
        for <[EMAIL PROTECTED]>; Mon, 10 Oct 2005 17:09:44 -0700 (PDT)
Received: from eggert by penguin.cs.ucla.edu with local (Exim 4.50)
        id 1EP7iD-0004aq-Fu
        for [EMAIL PROTECTED]; Mon, 10 Oct 2005 17:09:45 -0700
To: [EMAIL PROTECTED]
Subject: flex generates a C file with improper macro defn; broke Bison 2.1
Message-Id: <[EMAIL PROTECTED]>
From: Paul Eggert <[EMAIL PROTECTED]>
Date: Mon, 10 Oct 2005 17:09:45 -0700
Delivered-To: [EMAIL PROTECTED]
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2005_01_02 
        (1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Level: 
X-Spam-Status: No, hits=-8.0 required=4.0 tests=BAYES_00,HAS_PACKAGE 
        autolearn=no version=2.60-bugs.debian.org_2005_01_02

Package: flex
Version: 2.5.31-34
Tags: patch upstream

flex 2.5.31-34 generates a C file that does not conform to the C
standard, because the code invokes gram_wrap() even though the
gram_wrap macro expects an argument.

This bug is also present in Debian stable, and its presence broke
Bison 2.1 because I used Debian stable flex to build Bison.  The bug's
effect is described in
<http://lists.gnu.org/archive/html/bug-bison/2004-02/msg00026.html>;
that message is for Bison 1.875 but the same problem occurs in the
Bison 2.1 distribution because of the bug in flex 2.5.31-31.
(I used flex 2.5.31-31 to generate both Bison 1.875 and Bison 2.1.)

I see from
<http://ftp.debian.org/debian/pool/main/f/flex/flex_2.5.31-34.diff.gz>
that the file
flex-2.5.31/{arch}/flex/flex--debian/flex--debian--2.5/[EMAIL 
PROTECTED]/patch-log/patch-2
logs the presence of the bug, but there isn't any patch installed.  I
suspect the patch got lost somehow so I'm filing this bug report.
Here is a patch.

2005-10-10  Paul Eggert  <[EMAIL PROTECTED]>

        * main.c (readin): Don't output an invalid macro definition for
        yywrap; some C compilers complain about this.

--- flex-2.5.31-34/main.c       2005-10-10 16:43:31.000000000 -0700
+++ flex-2.5.31-34-yywrap/main.c        2005-10-10 16:49:11.000000000 -0700
@@ -1560,7 +1560,7 @@ void readin ()
     }
 
        if (!do_yywrap) {
-               outn ("\n#define yywrap(n) 1");
+               outn ("\n#define yywrap() 1");
                outn ("#define YY_SKIP_YYWRAP");
        }
 

---------------------------------------
Received: (at 333231-done) by bugs.debian.org; 21 Oct 2005 06:31:59 +0000
>From [EMAIL PROTECTED] Thu Oct 20 23:31:59 2005
Return-path: <[EMAIL PROTECTED]>
Received: from host-12-107-230-171.dtccom.net 
(glaurung.internal.golden-gryphon.com) [12.107.230.171] 
        by spohr.debian.org with esmtp (Exim 3.36 1 (Debian))
        id 1ESqRb-00037J-00; Thu, 20 Oct 2005 23:31:59 -0700
Received: from glaurung.internal.golden-gryphon.com ([EMAIL PROTECTED] 
[127.0.0.1])
        by glaurung.internal.golden-gryphon.com (8.13.5/8.13.5/Debian-3) with 
ESMTP id j9L6Sj5k025365
        (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT);
        Fri, 21 Oct 2005 01:28:48 -0500
Received: (from [EMAIL PROTECTED])
        by glaurung.internal.golden-gryphon.com (8.13.5/8.13.5/Submit) id 
j9L6SiLL025363;
        Fri, 21 Oct 2005 01:28:44 -0500
X-Authentication-Warning: glaurung.internal.golden-gryphon.com: srivasta set 
sender to srivasta(va, manoj)@debian.org using -f
From: Manoj Srivastava <[EMAIL PROTECTED] (va, manoj)>
To: Paul Eggert <[EMAIL PROTECTED]>
Cc: [EMAIL PROTECTED]
Subject: Re: Bug#333231: flex generates a C file with improper macro defn; 
broke Bison 2.1
Organization: The Debian Project
References: <[EMAIL PROTECTED]>
User-Agent: Gnus/5.110004 (No Gnus v0.4) Emacs/22.0.50 (gnu/linux) 
(i686-pc-linux-gnu)
Face: iVBORw0KGgoAAAANSUhEUgAAACYAAAAwCAMAAABKbPgaAAAAM1BMVEUAAADIjH/0rp1KPz79
        
0b+ic2nlpJc2Ly2AY17VlYb4uqi2gHQXFBN2WVXgno5iT02Xa2Nx+jaIAAACVElEQVQ4jeWU23bj
        
IAxFLUAggQX6/6+dI9LGTpo+9mlYiXNhc3TnOP50naZE0tqvgEk+soutnNfQ8yPTWMTENhNrjI+Y
        
+N7POVt8tAzpn2vJlsmttbyfrdkP7hx5iezteGzsbOts7xT+tC1mcG+LtRP2X/16bEQExuyx1uZW
        
vscrAWUT8aE0aDBeBuw8nS5u4WgWyDCllOZUBeyWgbWbGrBsTDpTx0qpphlcYPcgJLvBXFClPMg5
        
6WH2JidLIAaDF5aAed7uPTH4bjw0bZvfajp2tHc1F+cBm+Vr9YomGSwNhbmcczYEWUu5MBpYvCLV
        
F+ZIKwQfYB+CBXnIRQFvIRhK6l96PemsFLEPFxi+MPxiTYH0Ave1InPsIYes3NJb42ytBSmmysyj
        
lIQYHJm6Im1WbQ0kWMesKFRFPKTDzJ3GhWUn2KWKEkWlKthoACLm2eWJQQh2qKbAUgQxa+8TVjn1
        
aySm8656ookCfCc5TRzvnZ6YOu3NpHg+uR5YuRkNF/b5IHq5Y7Ve6c2+sR4hqIZ3+5DCt3ukh8Eo
        
vFIXVJxqfMdbkd/BF3YaQkB/2RIUHPMS7RLVAHefrYzWZVQ/ei4peBsROFLi90ltQyvF5I05t4Zs
        
L4C9DODJ2AZCUf8UitGjCIdfx15QQkfZibTOGT3edxns5fY6F2rstKcTwiiaJnQwvYkdzTlaTqNH
        
IkSmGdLrON45tGsMNDoSYr4bxH5emHEFaoFjKBahHXFXfLx9cR9p6ejJXihuxPz57gWHZkWovbPl
        9gsU8eImtBi++3D+f+sfT/Mg79fyEz8AAAAASUVORK5CYII=
X-URL: http://www.debian.org/%7Esrivasta/
Mail-Copies-To: nobody
X-Hashcash: 1:25:051021:[EMAIL 
PROTECTED]::B2KmNY7yjaH55rsK:0000000000000000000000000000000000000000000OjMP
X-Hashcash: 1:25:051021:[EMAIL 
PROTECTED]::W9t811VCAb5hyCU8:000000000000000000000000000000000000002zw2V
X-Face: [EMAIL PROTECTED]/;Y^gTjR\T^"B'fbeuVGiyKrvbfKJl!^e|e:iu(kJ6c|QYB57LP*|t
 &YlP~HF/=h:[EMAIL PROTECTED]:6Cj0kd#4]>*D,|0djf'CVlXkI,>aV4\}?d_KEqsN{Nnt7
 78"OsbQ["56/!nisvyB/uA5Q.{)gm6?q.j71ww.>b9b]-sG8zNt%KkIa>xWg&1VcjZk[hBQ>]j~`Wq
 Xl,y1a!(>6`UM{~'X[Y_,Bv+}=L\SS*mA8=s;!=O`ja|@PEzb&i0}Qp,`Z\:6:OmRi*
X-Hashcash: 1:25:051021:[EMAIL 
PROTECTED]::vwA8eG9qnwZUGqk/:000000000000000000000000000000000000000000526CY
X-Hashcash: 1:25:051021:[EMAIL 
PROTECTED]::3LDn8xJutx11/j2Y:0000000000000000000000000000000000R+Ey
Date: Fri, 21 Oct 2005 01:28:44 -0500
In-Reply-To: <[EMAIL PROTECTED]> (Paul Eggert's message of
        "Mon, 10 Oct 2005 17:09:45 -0700")
Message-ID: <[EMAIL PROTECTED]>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-CRM114-Score: -29.6401
X-CRM114-Status: Good  ( pR: -29.6401 )
X-SA-Orig: -9.899, -29.6401
X-Spam-Value: -15.9901166666667
X-Grey: White
X-SA-Rep: -15.9901166666667 ALL_TRUSTED,BAYES_00,HASHCASH_25
X-Scanned-By: MIMEDefang version 2.53 (www . roaringpenguin . com / mimedefang) 
on 192.168.1.10
Delivered-To: [EMAIL PROTECTED]
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2005_01_02 
        (1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Level: 
X-Spam-Status: No, hits=-6.0 required=4.0 tests=BAYES_00,HAS_BUG_NUMBER 
        autolearn=no version=2.60-bugs.debian.org_2005_01_02

On Mon, 10 Oct 2005 17:09:45 -0700, Paul Eggert <[EMAIL PROTECTED]> said: 

> flex 2.5.31-34 generates a C file that does not conform to the C
> standard, because the code invokes gram_wrap() even though the
> gram_wrap macro expects an argument.

        You can leave macro arguments empty; this is not an error.  You
 cannot leave out arguments entirely; if a macro takes two arguments,
 there must be exactly one comma at the top level of its argument
 list. (See $6.10.2, and $6.10.3, (C)ISO/IEC ISO/IEC 9899:1999 (E) for
 details).

> I see from
>> http://ftp.debian.org/debian/pool/main/f/flex/flex_2.5.31-34.diff.gz>
> that the file
> flex-2.5.31/{arch}/flex/flex--debian/flex--debian--2.5/[EMAIL 
> PROTECTED]/patch-log/patch-2
> logs the presence of the bug, but there isn't any patch installed.
> I suspect the patch got lost somehow so I'm filing this bug report.
> Here is a patch.

        Actually, no. The fix was removed since it caused all the
 tests to fail, and is strictly correct according to c99. Also, I did
 test to see if this was a serious problem: These are pretty
 aggressive warning flags
,----
| [EMAIL PROTECTED]:~/flex-2.5.31/tests/test-array-nr$  i486-linux-gnu-gcc \
|   -std=gnu99 -pedantic -Wall -W -Wconversion -Wshadow  -Wpointer-arith \
|   -Wcast-qual -Wcast-align -Wunreachable-code  -Wbad-function-cast    \
|   -Wmissing-declarations -Wmissing-prototypes -Wwrite-strings         \
|   -Waggregate-return -Wpadded -W -Wfloat-equal -Wshadow -Wconversion  \
|   -Wchar-subscripts -Wnested-externs -Wstrict-prototypes  -Wformat    \
|   -Wcomment -fshort-enums -fno-common -Dgets=DONT_USE_GETS -Dlint     \
|   -Wpacked  -Winline -c -o scanner.o -I. -I../.. -I../..  -g -O2      \
|   scanner.c  
| scanner.l: In function 'testlex':
| scanner.l:43: warning: passing argument 2 of 'fwrite' as unsigned due to 
prototype
| scanner.c: In function 'test_scan_string':
| scanner.c:1430: warning: passing argument 2 of 'test_scan_bytes' as signed 
due to prototype
| scanner.c: At top level:
| scanner.c:1503: warning: no previous prototype for 'testget_lineno'
| scanner.c:1512: warning: no previous prototype for 'testget_in'
| scanner.c:1520: warning: no previous prototype for 'testget_out'
| scanner.c:1528: warning: no previous prototype for 'testget_leng'
| scanner.c:1537: warning: no previous prototype for 'testget_text'
| scanner.c:1546: warning: no previous prototype for 'testset_lineno'
| scanner.c:1558: warning: no previous prototype for 'testset_in'
| scanner.c:1563: warning: no previous prototype for 'testset_out'
| scanner.c:1568: warning: no previous prototype for 'testget_debug'
| scanner.c:1573: warning: no previous prototype for 'testset_debug'
| scanner.c:1579: warning: no previous prototype for 'testlex_destroy'
| scanner.c: In function 'testlex':
| scanner.c:823: warning: will never be executed
| scanner.c:693: warning: will never be executed
| scanner.c:673: warning: will never be executed
| scanner.c: In function 'testpop_buffer_state':
| scanner.c:1331: warning: will never be executed
| scanner.c: In function 'testlex_destroy':
| scanner.c:1583: warning: will never be executed
`----

        manoj

-- 
You're at the end of the road again.
Manoj Srivastava   <[EMAIL PROTECTED]>  <http://www.debian.org/%7Esrivasta/>
1024D/BF24424C print 4966 F272 D093 B493 410B  924B 21BA DABB BF24 424C


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to