develooper Front page | perl.perl5.porters | Postings from April 2000

5.6.0 modified leftbracket handling breaks diskdrake

Thread Next
From:
Stephane Payrard
Date:
April 18, 2000 12:13
Subject:
5.6.0 modified leftbracket handling breaks diskdrake
Message ID:
20000418221312.A2555@bib

I have tried to run Mandrake diskdrake using perl 5.6.0.
The following code breaks because toke.c wrongly guess 
the number 1 to be the key of a hash and returns HASHBRACK
as token for the left bracket.

    gtkpack_($box, map { 1, $_} @_);

diskdrake fix:
    gtkpack_($box, map { (1, $_) } @_);

Apparently, the error has been introduced when utf-ing the code.
The patch:

--- toke.c.orig	Tue Mar 21 06:30:21 2000
+++ toke.c	Tue Apr 18 21:55:34 2000
@@ -3063,7 +3063,7 @@
 		    }
 		    t++;
 		}
-		else if (isALNUM_lazy_if(t,UTF)) {
+		else if (isIDFIRST_lazy_if(t,UTF)) {
 		    t += UTF8SKIP(t);
 		    while (t < PL_bufend && isALNUM_lazy_if(t,UTF))


BTW: may be we should obsolete the comma as separator between key and value?

-- 
  Stéphane Payrard
   email   : properler@freesurf.fr
   portable: 06 60 95 82 69
  

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About