develooper Front page | perl.perl5.porters | Postings from May 2010

Re: [perl #74022] What to do in 5.12.1? -- Parser hangs on some Unicode numbers and symbols in identifiers

Thread Previous | Thread Next
From:
Father Chrysostomos
Date:
May 3, 2010 06:43
Subject:
Re: [perl #74022] What to do in 5.12.1? -- Parser hangs on some Unicode numbers and symbols in identifiers
Message ID:
649BB965-6FF7-4AE8-9661-9395054C9BBD@cpan.org

On May 2, 2010, at 3:39 PM, karl williamson wrote:

> Since this causes Perl to hang, I think it should be addressed  
> somehow in 5.12.1.  It may be that the thing to do is just document  
> it.

Perhaps die in scan_word if the identifier has no length?

> It's been around since 2007.  I'm still looking at how things are  
> done currently, and a number of things appear wrong to me, but  
> that's an initial take, subject to further consideration.
>
> Father Chrysostomos wrote:
>> On Apr 27, 2010, at 6:56 PM, karl williamson wrote:
>>> To summarize, I propose that we use Unicode's XID_Start and  
>>> XID_Continue properties in 5.14, even though that breaks one of  
>>> our tests, and possibly existing code.
>> Would we change the meanings of is_utf8_idcont and is_utf8_idfirst,  
>> or introduce new functions?
>

> But I need to further study things to come up with a recommendation

In anticipation of what I think your recommendation will be, I’m  
sending a patch that uses the XID- variants.

>
>
>> In anticipation of this change, I’ve attached a patch that corrects  
>> the test in utf8.t to use ¡ instead of ·. I’ve also moved the test  
>> outside of the eval, so it will still run (and fail) if the  
>> compilation fails, instead of causing an invalid test count.
> Thanks.  Have you considered adding a timeout? test.pl has one that  
> will kill the test script if Perl hangs.

That patch (open_jE1FFxzb.txt) was to fix the existing ‘qq· test ·’  
test. That one doesn’t hang.

This new patch adds a test to t/comp/parser.t, which does not use test.pl 
.  Should it be changed so we can add a watchdog(60), or should the  
test go elsewhere?

The open_jE1FFxzb.txt patch should be applied first, to keep tests  
passing.


Thread Previous | 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