Skip Menu |

This queue is for tickets about the Treex-PML CPAN distribution.

Report information
The Basics
Id: 108420
Status: resolved
Priority: 0/
Queue: Treex-PML

People
Owner: CHOROBA [...] cpan.org
Requestors: a.dimitriadis [...] uu.nl
Cc:
AdminCc:

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



Subject: Backwards test in Treex::PML::Node::validate_subtree()
Date: Tue, 3 Nov 2015 21:43:26 +0100
To: <bug-Treex-PML [...] rt.cpan.org>
From: Alexis Dimitriadis <a.dimitriadis [...] uu.nl>
Dear PML maintainers, In Node.pm, the following code is broken: sub Treex::PML::Node::validate_subtree { my ($node, $log) = @_; if (defined $log and UNIVERSAL::isa($log,'ARRAY')) { croak __PACKAGE__."::validate: log must be an ARRAY reference"; } < etc. > The check is wrong: the second test should be negated, i.e., "and ! UNIVERSAL::isa($log, 'ARRAY')". The way it is right now, passing an array reference in the optional argument results in an error. Best, Alexis