Skip Menu |
 

This queue is for tickets about the Text-Balanced CPAN distribution.

Report information
The Basics
Id: 42659
Status: new
Priority: 0/
Queue: Text-Balanced

People
Owner: Nobody in particular
Requestors: derhoermi [...] gmx.net
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



CC: bug-text-balanced [...] rt.cpan.org
X-Y-GMX-Trusted: 0
MIME-Version: 1.0
X-Spam-Status: No, hits=-0.0 required=8.0 tests=SPF_PASS
X-Mailer: Forte Agent 3.3/32.846
X-Provags-ID: V01U2FsdGVkX19bcRVONXZbhcaC9AJRlewZYBUOvex2wFGCHsGSWr 8vH95FiHCa5bsy
X-Authenticated: #723575
content-type: text/plain; charset="utf-8"
Message-ID: <m1cgn4pghak20abd11uh7rc5smnsubqu5r [...] hive.bjoern.hoehrmann.de>
Received: from la.mx.develooper.com (x1.develooper.com [63.251.223.170]) by diesel.bestpractical.com (Postfix) with SMTP id B6C4B4D8084 for <bug-text-balanced [...] rt.cpan.org>; Thu, 22 Jan 2009 04:47:51 -0500 (EST)
Received: (qmail 9742 invoked by uid 103); 22 Jan 2009 09:47:50 -0000
Received: from x16.dev (10.0.100.26) by x1.dev with QMQP; 22 Jan 2009 09:47:50 -0000
Received: from mail.gmx.net (HELO mail.gmx.net) (213.165.64.20) by 16.mx.develooper.com (qpsmtpd/0.43rc1) with SMTP; Thu, 22 Jan 2009 01:47:46 -0800
Received: (qmail invoked by alias); 22 Jan 2009 09:47:42 -0000
Received: from dslb-088-074-175-196.pools.arcor-ip.net (EHLO hive) [88.74.175.196] by mail.gmx.net (mp056) with SMTP; 22 Jan 2009 10:47:42 +0100
Delivered-To: cpan-bug+text-balanced [...] diesel.bestpractical.com
Subject: Adjacent anonymous subrules misparsed
Return-Path: <derhoermi [...] gmx.net>
X-Original-To: bug-text-balanced [...] rt.cpan.org
X-Spam-Check-BY: 16.mx.develooper.com
Date: Thu, 22 Jan 2009 10:47:43 +0100
X-Spam-Level: *
X-Fuhafi: 0.53
To: bug-parse-recdescent [...] rt.cpan.org
Content-Transfer-Encoding: 8bit
From: Bjoern Hoehrmann <derhoermi [...] gmx.net>
X-RT-Original-Encoding: ISO-8859-1
Content-Length: 1120
Hi, With v1.96.0 of Parse::RecDescent and Text::Balanced v2.0.0 the following grammar is not parsed as I would expect: A: ( x x ) ( x x ) This results in 'Untranslatable item encountered: ")"'. This appears to be a logic error in the code around line 1920 starting with ... elsif ($grammar =~ m/(?=$IMPLICITSUBRULE)/gco and do { ($code) = extract_codeblock($grammar,'{([',undef,'(',1); $code }) { $code =~ s/\A\s*\(|\)\Z//g; ... Here $code is '( x x ) ( x x )' and is then turned into 'x x ) ( x x'. I am somewhat unsure from the documentation of Text::Balanced whether it is supposed to return '( x x ) ( x x )' rather than '( x x )', it may be a good idea to document that one way or the other. (By the way, the code passes five parameters to extract_codeblock while it only seems to document four parameters, but then uses them all.) regards, -- Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de 25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.